Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/FFmpeg/FFmpeg.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHendrik Leppkes <h.leppkes@gmail.com>2013-05-04 13:17:00 +0400
committerMichael Niedermayer <michaelni@gmx.at>2013-05-04 15:20:19 +0400
commitd18341fb1121332056aecc00096159df16d01107 (patch)
treec9cefcb77802301661fa59f38d9259ade14b6de7
parent23a7c32a7ade12044c600aa48966829c53dcc836 (diff)
aacdec: free frame buffer if no audio was decoded
If no decoding error was detected, but still no audio was decoded, the frame needs to be free'ed, or it will leak. Fixes part of ticket #2095 Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
-rw-r--r--libavcodec/aacdec.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/libavcodec/aacdec.c b/libavcodec/aacdec.c
index f60060adb5..cd7bbb0adb 100644
--- a/libavcodec/aacdec.c
+++ b/libavcodec/aacdec.c
@@ -2611,6 +2611,8 @@ static int aac_decode_frame_int(AVCodecContext *avctx, void *data,
if (samples)
ac->frame->nb_samples = samples;
+ else
+ av_frame_unref(ac->frame);
*got_frame_ptr = !!samples;
if (is_dmono) {