[FFmpeg-cvslog] avfilter:audio: fix shadowed AVFrame *out

Paul B Mahol git at videolan.org
Tue Oct 6 09:57:37 CEST 2015


ffmpeg | branch: master | Paul B Mahol <onemda at gmail.com> | Tue Oct  6 09:50:30 2015 +0200| [755242b9121331af71caf8b47517335c388d8511] | committer: Paul B Mahol

avfilter:audio: fix shadowed AVFrame *out

Signed-off-by: Paul B Mahol <onemda at gmail.com>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=755242b9121331af71caf8b47517335c388d8511
---

 libavfilter/af_agate.c       |    4 ++--
 libavfilter/af_stereotools.c |    4 ++--
 libavfilter/af_stereowiden.c |    4 ++--
 3 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/libavfilter/af_agate.c b/libavfilter/af_agate.c
index 46ee226..7781a9c 100644
--- a/libavfilter/af_agate.c
+++ b/libavfilter/af_agate.c
@@ -158,14 +158,14 @@ static int filter_frame(AVFilterLink *inlink, AVFrame *in)
     const double attack_coeff = s->attack_coeff;
     const double release_coeff = s->release_coeff;
     const double level_in = s->level_in;
-    AVFrame *out = NULL;
+    AVFrame *out;
     double *dst;
     int n, c;
 
     if (av_frame_is_writable(in)) {
         out = in;
     } else {
-        AVFrame *out = ff_get_audio_buffer(inlink, in->nb_samples);
+        out = ff_get_audio_buffer(inlink, in->nb_samples);
         if (!out) {
             av_frame_free(&in);
             return AVERROR(ENOMEM);
diff --git a/libavfilter/af_stereotools.c b/libavfilter/af_stereotools.c
index f4030b7..6a3265d 100644
--- a/libavfilter/af_stereotools.c
+++ b/libavfilter/af_stereotools.c
@@ -145,7 +145,7 @@ static int filter_frame(AVFilterLink *inlink, AVFrame *in)
     const int phase_l = floor(s->phase_l + 0.5);
     const int phase_r = floor(s->phase_r + 0.5);
     double *buffer = s->buffer;
-    AVFrame *out = NULL;
+    AVFrame *out;
     double *dst;
     int nbuf = inlink->sample_rate * (FFABS(delay) / 1000.);
     int n;
@@ -154,7 +154,7 @@ static int filter_frame(AVFilterLink *inlink, AVFrame *in)
     if (av_frame_is_writable(in)) {
         out = in;
     } else {
-        AVFrame *out = ff_get_audio_buffer(inlink, in->nb_samples);
+        out = ff_get_audio_buffer(inlink, in->nb_samples);
         if (!out) {
             av_frame_free(&in);
             return AVERROR(ENOMEM);
diff --git a/libavfilter/af_stereowiden.c b/libavfilter/af_stereowiden.c
index 8f671ca..7c5f2d4 100644
--- a/libavfilter/af_stereowiden.c
+++ b/libavfilter/af_stereowiden.c
@@ -90,14 +90,14 @@ static int filter_frame(AVFilterLink *inlink, AVFrame *in)
     const float drymix = s->drymix;
     const float crossfeed = s->crossfeed;
     const float feedback = s->feedback;
-    AVFrame *out = NULL;
+    AVFrame *out;
     float *dst;
     int n;
 
     if (av_frame_is_writable(in)) {
         out = in;
     } else {
-        AVFrame *out = ff_get_audio_buffer(inlink, in->nb_samples);
+        out = ff_get_audio_buffer(inlink, in->nb_samples);
         if (!out) {
             av_frame_free(&in);
             return AVERROR(ENOMEM);



More information about the ffmpeg-cvslog mailing list