A very valid point indeed.
___
Openocd-development mailing list
Openocd-development@lists.berlios.de
https://lists.berlios.de/mailman/listinfo/openocd-development
velopment-boun...@lists.berlios.de] On Behalf Of Redirect
"Slash" NIL
Sent: Saturday, October 17, 2009 6:14 PM
To: openocd-development@lists.berlios.de
Subject: Re: [Openocd-development] [PATCH] cast from long to HANDLER on
MinGW-W64
2009/10/17 David Brownell mailto:davi...@pacbell.net>>
What&
Forgot a cast on _get_osfhandle(i);
Here's a safer (and hopefully final) version.
patch_long_to_handler_mingw_w64_v3.diff
Description: Binary data
___
Openocd-development mailing list
Openocd-development@lists.berlios.de
https://lists.berlios.de/mailman
2009/10/18 Igor Skochinsky
> Actually, in VC9 it returns intptr_t (MSDN is wrong here):
>
> _CRTIMP intptr_t __cdecl _get_osfhandle(_In_ int _FileHandle);
> (from io.h)
>
> So it might be worth it to get mingw people to fix their headers...
>
Actually, the io.h from MinGW-W64 does have the same
On Saturday 17 October 2009, Redirect "Slash" NIL wrote:
> >
> > The "0 +" is mutant...
> >
>
> Yeah. The problem here is that HANDLE is typedef'd as void* (in winnt.h),
> whereas _get_osfhandle() returns a long (
> http://msdn.microsoft.com/en-us/library/ks2530z6.aspx), and gcc insists on
> retur
Hello Redirect,
Sunday, October 18, 2009, 1:14:20 AM, you wrote:
RSN> Yeah. The problem here is that HANDLE is typedef'd as void* (in
RSN> winnt.h), whereas _get_osfhandle() returns a long
RSN> (http://msdn.microsoft.com/en-us/library/ks2530z6.aspx), and gcc
RSN> insists on returning a warning wh
2009/10/17 David Brownell
>
> What's with the strange "(HANDLE)(0 + _get_osfhandle())"?
>
> The "0 +" is mutant...
>
Yeah. The problem here is that HANDLE is typedef'd as void* (in winnt.h),
whereas _get_osfhandle() returns a long (
http://msdn.microsoft.com/en-us/library/ks2530z6.aspx), and gcc
What's with the strange "(HANDLE)(0 + _get_osfhandle())"?
The "0 +" is mutant...
___
Openocd-development mailing list
Openocd-development@lists.berlios.de
https://lists.berlios.de/mailman/listinfo/openocd-development
This fix addresses the cast warnings issued on MinGW-W64 when casting a long
to HANDLER in replacement.c
Also removes the need for a temporary variable.
patch_long_to_handler_mingw_w64.diff
Description: Binary data
___
Openocd-development mailing list
O