[FFmpeg-devel] [PATCH] API changes in ffmpeg.c

Stefano Sabatini stefano.sabatini-lala
Fri Apr 10 14:55:41 CEST 2009


On date Friday 2009-04-10 13:55:52 +0200, Thilo Borgmann encoded:
> Ok a new thread for the API changes in ffmpeg.c, cut off from the  
> original thread:
>
> Stefano Sabatini schrieb:
>> On date Wednesday 2009-04-08 16:09:01 +0200, Thilo Borgmann encoded:
>> [...]
>>   
>>> diff --git a/ffmpeg.c b/ffmpeg.c
>>> index cb15120..4944811 100644
>>> --- a/ffmpeg.c
>>> +++ b/ffmpeg.c
>>> ...
>>> -                ptr += ret;
>>> -                len -= ret;
>>> +                avpkt.data += ret;
>>> +                avpkt.size -= ret;
>>>                  /* Some bug in mpeg audio decoder gives */
>>>                  /* data_size < 0, it seems they are overflows */
>>>                  if (data_size <= 0) {
>>> @@ -1245,8 +1247,8 @@ static int output_packet(AVInputStream *ist, int ist_index,
>>>                      /* XXX: allocate picture correctly */
>>>                      avcodec_get_frame_defaults(&picture);
>>>  -                    ret = avcodec_decode_video(ist->st->codec,
>>> -                                               &picture, &got_picture, ptr, len);
>>> +                    ret = avcodec_decode_video2(ist->st->codec,
>>> +                                               &picture, &got_picture, pkt);
>>>     
>>
>> Crash here.
>>
>> Make sure you test your patches with make test before to submit them.
[...]
> Crash fixed, revision 1 of the patch attached. More comments on this  
> already posted in the originating thread.

The changes required were trivial and the original one was already
OKed, so tested and applied.

Regards.
-- 
FFmpeg = Faithful and Faboulous Multimedia Plastic Elected Ghost



More information about the ffmpeg-devel mailing list