lavfi/earwax: add missing NULL check in filter_samples()
authorStefano Sabatini <stefasab@gmail.com>
Sat, 3 Nov 2012 23:17:27 +0000 (00:17 +0100)
committerStefano Sabatini <stefasab@gmail.com>
Sat, 3 Nov 2012 23:17:27 +0000 (00:17 +0100)
libavfilter/af_earwax.c

index 95602a1..2e2cac3 100644 (file)
@@ -129,6 +129,8 @@ static int filter_samples(AVFilterLink *inlink, AVFilterBufferRef *insamples)
                                   insamples->audio->nb_samples);
     int ret;
 
+    if (!outsamples)
+        return AVERROR(ENOMEM);
     avfilter_copy_buffer_ref_props(outsamples, insamples);
 
     taps  = ((EarwaxContext *)inlink->dst->priv)->taps;