[Ffmpeg-devel] [PATCH] Merge some changes from xine-lib's ffmpeg patch

Måns Rullgård mru
Thu Jun 29 01:59:34 CEST 2006


Michael Niedermayer <michaelni at gmx.at> writes:

>> diff --git a/libavcodec/interplayvideo.c b/libavcodec/interplayvideo.c
>> index 73165e7..588485a 100644
>> --- a/libavcodec/interplayvideo.c
>> +++ b/libavcodec/interplayvideo.c
>> @@ -49,7 +49,11 @@ #define DEBUG_INTERPLAY 0
>>  #if DEBUG_INTERPLAY
>>  #define debug_interplay(x,...) av_log(NULL, AV_LOG_DEBUG, x, __VA_ARGS__)
>>  #else
>> -static inline void debug_interplay(const char *format, ...) { }
>> +static inline void
>> +#ifdef __GNUC__
>> +__attribute__ ((__format__ (__printf__, 1, 2)))
>> +#endif
>> +debug_interplay(const char *format, ...) { }
>>  #endif
>
> i leave this to the interplayvideo.c maintainer to decide

It strikes me as odd adding that __attribute__ to a function that does
nothing.

>> diff --git a/libavutil/common.h b/libavutil/common.h
>> index ae32512..c951f5b 100644
>> --- a/libavutil/common.h
>> +++ b/libavutil/common.h
>> @@ -288,7 +288,7 @@ #    endif
>>  
>>  /* debug stuff */
>>  
>> -#    ifndef DEBUG
>> +#    if !defined(DEBUG) && !defined(NDEBUG)
>>  #        define NDEBUG
>>  #    endif
>>  #    include <assert.h>
>
> what is the purpose of this change?

It will avoid a warning if NDEBUG has already been defined (on the
command line or elsewhere).

-- 
M?ns Rullg?rd
mru at inprovide.com




More information about the ffmpeg-devel mailing list