[MPlayer-dev-eng] [PATCH] Yet another batch of warning fixes :->
Arpi
arpi at thot.banki.hu
Tue Dec 10 13:42:24 CET 2002
Hi,
> > > > it'll break code on 64bit platforms badly
> > >
> > > Will it? How about uint32_t then? And avifile's loader has those
> > what is the problem with int ?
>
> Lots and lots of warnings about incompatible types.
then uint32_t won't help there... (it's typedef'ed as int by inttypes.h)
try to fix the causes instead of workarounding them...
> > > defines exactly like in my patch.
> > yes and avifile is broken too. anyway avifile duplicates all those
> > structs with int (instead of DWORD) in its include/ dir, and us eit for
> > non-x86 platforms.
>
> Interesting. I couldn't find it, however. If you could point me to the
> right file... :-/
i mean in avifile sources, the structs (BITMAPINFOHEADER etc) are defined
twice. once in its include/ (used on all platforms) and once in
plugins/libwin32/loader/wine/* used only for x86. So, for avifile the 'long'
is ok, as they use the wine headers on x86 only.
but in mplayer, the windef.h is included in stheader.h which is used in all
platforms, including 64bit ones. the long was changed to int by a patch for
Alpha support long time ago.
> > > > > - printf("%.4s ", &c->fcc);
> > > > > + printf("%.4d ", c->fcc);
> > > >
> > > > heh?
> > > > %.4d won't print fourcc but a silly number
> > >
> > > Hmmm. Right, sorry, missed this one (although there's another done right).
> > another? where?
>
> One was in loader/dshow/DS_VideoDecoder.c and the other in
> loader/dmo/DMO_VideoDecoder.c
they are 99% same file, just DS_ -> DMO_ and a few lines changed.
> > > > > - *lpFilePart = strrchr(lpFileName, '\\');
> > > > > + lpFilePart = strrchr(lpFileName, '\\');
> > > > > else
> > > > > - *lpFilePart = lpFileName;
> > > > > + lpFilePart = lpFileName;
> > > >
> > > > looks bad
> > >
> > > But it's not bad. lpFilePart is LPTSTR and that is char *.
> > imho it's char** (Long Pointer To STRing)
>
> YHO is wrong. :-))
> loader/wine/windef.h:
> [...]
> typedef char CHAR;
> [...]
> typedef CHAR *LPSTR;
hmm
> [...]
> > > > > -//#include <string.h> // FIXME: conflicts with fs.h
> > > > > +#include <string.h> // FIXME: conflicts with fs.h
> > > > ^^^^^^^^^^^^^^^^^^^
> > >
> > > Oh, this one is interesting. I couldn't find any fs.h file on my system
> > > and in mplayer sources. WTF is it?
> >
> > neither me, but some broken glibc versions / distribs had this problem.
> > a warning is still better than a non-compiling mplayer.
>
> Agreed. But you don't mind my including this in the RPMs?
> They're compiled on my system and my glibc isn't broken.
ok
A'rpi / Astral & ESP-team
--
Developer of MPlayer, the Movie Player for Linux - http://www.MPlayerHQ.hu
More information about the MPlayer-dev-eng
mailing list