Skip to content
Snippets Groups Projects
Commit 42da8ea8 authored by Ronald S. Bultje's avatar Ronald S. Bultje Committed by Diego Biurrun
Browse files

LATM/AAC: Free previously initialized context on reinit.


Fixes memory leaks which are the result of overwriting already-initialized
MDCT contexts during context reinitialization, e.g. in valgrind
fate-aac-latm_000000001180bc60.

Signed-off-by: default avatarDiego Biurrun <diego@biurrun.de>
parent 0a6db2a2
No related branches found
No related tags found
No related merge requests found
......@@ -2464,6 +2464,7 @@ static int latm_decode_frame(AVCodecContext *avctx, void *out, int *out_size,
*out_size = 0;
return avpkt->size;
} else {
aac_decode_close(avctx);
if ((err = aac_decode_init(avctx)) < 0)
return err;
latmctx->initialized = 1;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment