ffmpeg | branch: master | Luca Barbato <[email protected]> | Sat Oct 18 16:58:47 2014 +0100| [96bfb677478514db73d1b63b4213c97ad4269e8f] | committer: Vittorio Giovara
nutdec: Prevent a memory corruption Chapters do not have an event_flags field. Bug-Id: CID 1231990 > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=96bfb677478514db73d1b63b4213c97ad4269e8f --- libavformat/nutdec.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/libavformat/nutdec.c b/libavformat/nutdec.c index 6c95d55..56d208f 100644 --- a/libavformat/nutdec.c +++ b/libavformat/nutdec.c @@ -461,7 +461,7 @@ static int decode_info_header(NUTContext *nut) int64_t value, end; char name[256], str_value[1024], type_str[256]; const char *type; - int *event_flags; + int *event_flags = NULL; AVChapter *chapter = NULL; AVStream *st = NULL; AVDictionary **metadata = NULL; @@ -529,7 +529,8 @@ static int decode_info_header(NUTContext *nut) } if (metadata && av_strcasecmp(name, "Uses") && av_strcasecmp(name, "Depends") && av_strcasecmp(name, "Replaces")) { - *event_flags |= metadata_flag; + if (event_flags) + *event_flags |= metadata_flag; av_dict_set(metadata, name, str_value, 0); } } _______________________________________________ ffmpeg-cvslog mailing list [email protected] http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
