[MPlayer-dev-eng] squelch some warnings (patches incl.)
Elias Pipping
elias at pipping.org
Sun Feb 24 20:25:33 CET 2008
On Sun, Feb 24, 2008 at 01:27:53PM +0100, Diego Biurrun wrote:
> On Fri, Feb 22, 2008 at 02:56:46PM +0100, Elias Pipping wrote:
> > --- libao2/ao_macosx.c
> > +++ libao2/ao_macosx.c
> > @@ -46,6 +46,7 @@
> > #include <inttypes.h>
> > #include <pthread.h>
> > #include <sys/types.h>
> > +#include <sys/time.h>
> > #include <unistd.h>
>
> This makes no sense to me. I did not see a warning in the list of
> warnings you posted that might be caused by this.
Indeed. The problem -- whatever it was -- must've been fixed by another
commit.
>
> > --- libmpcodecs/mp_image.h (revision 26061)
> > +++ libmpcodecs/mp_image.h (working copy)
> > @@ -1,5 +1,6 @@
> > #ifndef MPLAYER_MP_IMAGE_H
> > #define MPLAYER_MP_IMAGE_H
> > +#include <stdlib.h>
>
> I have a more extensive solution in my local tree since some time, I
> will clean it up and post it now.
Looking forward to that.
On a sidenote (replying here because Michael Niedermayer did not cc me):
libavcodec/snow.c basically looks like this:
#define QUANTIZE2 0
#if QUANTIZE2==1
static void dwt_quantize(<args>){
<implementation>
}
#endif
if(QUANTIZE2)
dwt_quantize(<args>);
The `#if QUANTIZE2==1` is effectively a `#if 0`. Hence, dwt_quantize()
is never declared. I don't see a reason to check for QUANTIZE2 at
runtime when it's already clear at compile-time that dwt_quantize() will
never be called. The fact that the definition of dwt_quantize() is
removed by the preprocessor but the invocation stays in, is what causes
the warning and my patch fixes that. Please let me know what made you
reject it.
-- Elias
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 186 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/mplayer-dev-eng/attachments/20080224/571532eb/attachment.pgp>
More information about the MPlayer-dev-eng
mailing list