This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [patch] gdbserver/win32-low.c: Fix printf-like formatting (was Re: [patch]: Replace stryoul call to fetch address)
> Date: Thu, 28 Feb 2013 09:54:26 +0100
> From: Corinna Vinschen <vinschen@redhat.com>
>
> DWORD is unsigned long on 32 bit Windows, right? So it is on 64 bit
> Windows as well, since Windows is a LLP64 system. 64 bit Cygwin OTOH
> will be LP64, so in 64 bit Cygwin's case, DWORD is defined as unsigned
> int for hopefully obvious reasons.
>
> So, using %ld with no cast will result in a GCC warning on 64 bit
> Cygwin, because DWORD is not long. %d would be right for 64 bit Cygwin,
> but might result in a warning on 32 bit Mingw/Cygwin and 64 bit Mingw.
Thanks.
(I think it's madness to use LP64 for Cygwin, but I doubt anyone will
hear me.)