[FFmpeg-cvslog] gxfenc: fix null ptr dereference

Michael Niedermayer git at videolan.org
Fri Oct 19 23:40:55 CEST 2012


ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Fri Oct 19 23:21:41 2012 +0200| [ba39303050c1e10c595a5495ab89f6a9e63fb667] | committer: Michael Niedermayer

gxfenc: fix null ptr dereference

Fixes CID703677
Signed-off-by: Michael Niedermayer <michaelni at gmx.at>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=ba39303050c1e10c595a5495ab89f6a9e63fb667
---

 libavformat/gxfenc.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavformat/gxfenc.c b/libavformat/gxfenc.c
index 1c2ff5d..9bec3d5 100644
--- a/libavformat/gxfenc.c
+++ b/libavformat/gxfenc.c
@@ -796,7 +796,7 @@ static int gxf_write_header(AVFormatContext *s)
     if (ff_audio_interleave_init(s, GXF_samples_per_frame, (AVRational){ 1, 48000 }) < 0)
         return -1;
 
-    if (tcr)
+    if (tcr && vsc)
         gxf_init_timecode(s, &gxf->tc, tcr->value, vsc->fields);
 
     gxf_init_timecode_track(&gxf->timecode_track, vsc);



More information about the ffmpeg-cvslog mailing list