[FFmpeg-devel] [PATCH] fix segfault in mxf demuxer

Baptiste Coudurier baptiste.coudurier at gmail.com
Mon Mar 21 21:09:27 CET 2011


Hi,

On 03/21/2011 05:40 AM, Tomas Härdin wrote:
> Nigel Touati-Evans skrev 2011-03-21 12:06:
>> Index: ffmpeg-dmo-0.5+svn20090508/libavformat/mxfdec.c
>> ===================================================================
>> --- ffmpeg-dmo-0.5+svn20090508.orig/libavformat/mxfdec.c    2011-03-21
>> 10:12:47.000000000 +0000
>> +++ ffmpeg-dmo-0.5+svn20090508/libavformat/mxfdec.c    2011-03-21
>> 10:17:13.000000000 +0000
>> @@ -723,13 +723,16 @@
>>                      break;
>>                  }
>>              }
>> -            if (!source_track) {
>> -                av_log(mxf->fc, AV_LOG_ERROR, "material track %d: no
>> corresponding source track found\n", material_track->track_id);
>> +            if (source_track) {
>> +                if (j+1 <
>> material_track->sequence->structural_components_count)
>> +                   av_log(mxf->fc, AV_LOG_WARNING, "material track
>> %d: found a source track so ignoring %d potential others\n",
>> material_track->track_id,
>> material_track->sequence->structural_components_count-j-1);
> 
> Break this long line up a bit.
> 
>>                  break;
>>              }
>>          }
>> -        if (!source_track)
>> +        if (!source_track) {
>> +            av_log(mxf->fc, AV_LOG_ERROR, "material track %d: no
>> corresponding source track found\n", material_track->track_id);
>>              continue;
>> +        }
>>
>>          st = av_new_stream(mxf->fc, source_track->track_id);
>>          if (!st) {
>>
>>
> 
> Looks OK otherwise to me. Baptiste?

Can we get a sample so I can reproduce the problem ?
I'd like to know where it exactly segv.

-- 
Baptiste COUDURIER
Key fingerprint                 8D77134D20CC9220201FC5DB0AC9325C5C1ABAAA
FFmpeg maintainer                                  http://www.ffmpeg.org



More information about the ffmpeg-devel mailing list