diff options
author | Michael Niedermayer <michael@niedermayer.cc> | 2016-04-28 20:49:13 +0200 |
---|---|---|
committer | Michael Niedermayer <michael@niedermayer.cc> | 2016-08-15 18:54:34 +0200 |
commit | 76fd8145a1e24e95eea9af70a3a25e518e2d0be1 (patch) | |
tree | af12e53ff6e25375a19092d184af8f461d93e498 | |
parent | 5af0ada4427140fc7d7abbd175ecad91433d155d (diff) | |
download | ffmpeg-76fd8145a1e24e95eea9af70a3a25e518e2d0be1.tar.gz |
avfilter/af_amix: dont fail if there are no samples in output_frame()
Fixes Ticket5326
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
(cherry picked from commit abc957e896beb3ce33c5691b9b3701993a381852)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
-rw-r--r-- | libavfilter/af_amix.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/libavfilter/af_amix.c b/libavfilter/af_amix.c index 9a3cbd4dcd..a03d773706 100644 --- a/libavfilter/af_amix.c +++ b/libavfilter/af_amix.c @@ -276,6 +276,9 @@ static int output_frame(AVFilterLink *outlink, int nb_samples) calculate_scales(s, nb_samples); + if (nb_samples == 0) + return 0; + out_buf = ff_get_audio_buffer(outlink, nb_samples); if (!out_buf) return AVERROR(ENOMEM); |