[FFmpeg-cvslog] avformat/mov: Fix deallocation when MOVStreamContext failed to allocate
Michael Niedermayer
git at videolan.org
Thu Aug 20 14:53:48 CEST 2015
ffmpeg | branch: release/2.4 | Michael Niedermayer <michael at niedermayer.cc> | Tue Jul 14 14:14:16 2015 +0200| [634605f79e361b06215f83724e2c67e192519c0e] | committer: Michael Niedermayer
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 at niedermayer.cc>
(cherry picked from commit 15629129dde771446a005282ee33c4ea1199e696)
Signed-off-by: Michael Niedermayer <michael at niedermayer.cc>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=634605f79e361b06215f83724e2c67e192519c0e
---
libavformat/mov.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/libavformat/mov.c b/libavformat/mov.c
index 7fafd5a..cabba37 100644
--- a/libavformat/mov.c
+++ b/libavformat/mov.c
@@ -3517,6 +3517,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);
More information about the ffmpeg-cvslog
mailing list