[FFmpeg-cvslog] r26343 - trunk/libavformat/mxfenc.c

bcoudurier subversion
Fri Jan 14 23:36:23 CET 2011


Author: bcoudurier
Date: Fri Jan 14 23:36:23 2011
New Revision: 26343

Log:
In mxf muxer, check the return value of gmtime, fix #2494

Modified:
   trunk/libavformat/mxfenc.c

Modified: trunk/libavformat/mxfenc.c
==============================================================================
--- trunk/libavformat/mxfenc.c	Fri Jan 14 23:32:26 2011	(r26342)
+++ trunk/libavformat/mxfenc.c	Fri Jan 14 23:36:23 2011	(r26343)
@@ -1379,6 +1379,8 @@ static int mxf_parse_mpeg2_frame(AVForma
 static uint64_t mxf_parse_timestamp(time_t timestamp)
 {
     struct tm *time = gmtime(&timestamp);
+    if (!time)
+        return 0;
     return (uint64_t)(time->tm_year+1900) << 48 |
            (uint64_t)(time->tm_mon+1)     << 40 |
            (uint64_t) time->tm_mday       << 32 |



More information about the ffmpeg-cvslog mailing list