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:
authorMichael Niedermayer <michael@niedermayer.cc>2015-07-14 15:14:16 +0300
committerMichael Niedermayer <michael@niedermayer.cc>2015-07-20 05:43:41 +0300
commite604662d047606263c0d7b81cccdb992a97cd0df (patch)
treef6fe362c5061486f188270b346bbf12452ddb0b4
parent77eddee375357452ec8e0e22b3cd877b38c0a5e9 (diff)
avformat/mov: Fix deallocation when MOVStreamContext failed to allocate
Fixes: 260813283176b57b3c9974fe284eebc3_signal_sigsegv_7ffff713351a_991_xtrem_e2_m64q15_a32sxx.3gp with memlimit of 262144 Found-by: Samuel Groß, Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michael@niedermayer.cc> (cherry picked from commit 15629129dde771446a005282ee33c4ea1199e696) Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
-rw-r--r--libavformat/mov.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/libavformat/mov.c b/libavformat/mov.c
index a9e1fa9189..4e38692ea5 100644
--- a/libavformat/mov.c
+++ b/libavformat/mov.c
@@ -3853,6 +3853,9 @@ static int mov_read_close(AVFormatContext *s)
AVStream *st = s->streams[i];
MOVStreamContext *sc = st->priv_data;
+ if (!sc)
+ continue;
+
av_freep(&sc->ctts_data);
for (j = 0; j < sc->drefs_count; j++) {
av_freep(&sc->drefs[j].path);