From 4d1fcd734e877b0bcb635664dbc7a0a0ff0627ec Mon Sep 17 00:00:00 2001 From: Michael Niedermayer Date: Wed, 6 Feb 2019 15:29:38 +0100 Subject: [PATCH] avformat/matroskadec: Do not leak queued packets on sync errors Fixes: memleak Fixes: clusterfuzz-testcase-minimized-audio_decoder_fuzzer-5649187601121280 Reported-by: Chris Cunningham Tested-by: Chris Cunningham Signed-off-by: Michael Niedermayer (cherry picked from commit d1afa7284c3feba4debfebf1b9cf8ad67640e34a) Signed-off-by: Michael Niedermayer --- libavformat/matroskadec.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavformat/matroskadec.c b/libavformat/matroskadec.c index 2daa1dba6f..2b42cff9a8 100644 --- a/libavformat/matroskadec.c +++ b/libavformat/matroskadec.c @@ -3541,7 +3541,7 @@ static int matroska_read_packet(AVFormatContext *s, AVPacket *pkt) ret = matroska_resync(matroska, pos); } - return ret; + return 0; } static int matroska_read_seek(AVFormatContext *s, int stream_index,