[FFmpeg-devel] [PATCH] 10-bit DNxHD support v4 review request

Baptiste Coudurier baptiste.coudurier at gmail.com
Fri Apr 8 21:55:46 CEST 2011


On 04/07/2011 05:29 PM, compn wrote:
> On Thu, 07 Apr 2011 16:25:26 -0700, Baptiste Coudurier wrote:
>> On 4/7/11 1:56 AM, Joseph Artsimovich wrote:
>>> Baptiste Coudurier wrote:
>>>>>>> +            assert(nbits < ctx->cid_table->bit_depth + 4);
>>>>>>
>>>>>> assert would kill the program.
>>>>> That would indicate a serious bug.  The assert merely checks we
>>>>> are not
>>>> reading past the end of a table.
>>>>> BTW, I've come by the following comment in mpegvideo_enc.c: //non
>>>>> c quantize code returns incorrect block_last_index FIXME If still
>>>>> true,
>>>> that could trigger this assert.
>>>>>
>>>>
>>>> It's a problem, but can this actually happen ?
>>>
>>> It happened to me once while I was in the middle of implementing
>>> 10bit support, which made me introduce that assert.  It hasn't
>>> happened since.  I hope it was because I did something wrong back
>>> then.
>>
>> Please check.
>>
> 
> by 'please check' do you mean run a fuzzer (like zzuf) on a 10bit file
> and make sure valgrind doesnt complain ? 

No, I mean check the code related to nbits and find the worst case, and
check that it will always be correct or can be wrong.

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


More information about the ffmpeg-devel mailing list