[Ffmpeg-devel] [PATCH] Add fact chunk to non-PCM wav

Michel Bardiaux mbardiaux
Mon Feb 12 16:57:46 CET 2007


Michael Niedermayer wrote:
> Hi
> 
> On Mon, Feb 12, 2007 at 04:20:51PM +0100, Michel Bardiaux wrote:
>> Michael Niedermayer wrote:
>>> Hi
>>>
>> [snip]
>>
>>>>>> BTW I feel that the 'assert' should be hunted down even more
>>>>>> ruthlessly as the dprintf. What do you think?
>>>>> some asserts are inappropriate they surely should be hunted down,
>>>>> others are valid and should not
>>>> I meant 'hunt assert to replace it by if+av_log+appropriate rror 
>>>> return'. Most people 'configure' in such a way that 'assert' is a
>>>> nop.
>>> and correct asserts should never be false so a nop is all fine of
>>> course one checking function parameters from exported functions is
>>> not correct ...
>> I dont understand you at all, which is usually a sign I should let the 
>> matters percolate through my dura mater for a few millenia...
> 
> an example of a correct assert() which should not be replaced is
> 
> if(is_prime(i)){
>     assert(i>1);
>     array[i-2]= 1;
> }
> 
> the truth return of a primality checking function gurantees that i must be
> larger then 1 as there is no prime smaller or equal to 1, the assert() here
> just checks that is_prime() which might be a very complex and hard to
> understand function is working correctly thus the assert() is only usefull
> for debuging and testing is_prime() but isnt really that usefull for non
> debug builds

Then we'll never be in agreement, because I prefer to take Murphy & 
Finagle into account, and activate all checks all the time unless they 
are *really* detrimental to speed (checking is_prime with 
assert(cardinal(factors(i))==2) would indeed by silly). So I'll drop the 
matter for now.

> 
> [...]
> 
> and patch looks ok

Applied. !!! CHAMPAGNE !!! (or SEKT, right?)

-- 
Michel Bardiaux
R&D Director
T +32 [0] 2 790 29 41
F +32 [0] 2 790 29 02
E mailto:mbardiaux at mediaxim.be

Mediaxim NV/SA
Vorstlaan 191 Boulevard du Souverain
Brussel 1160 Bruxelles
http://www.mediaxim.com/




More information about the ffmpeg-devel mailing list