[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Use Get/SetThreadErrorMode if it is available (on Windows 7 and abov
From: |
Ralf Wildenhues |
Subject: |
Re: Use Get/SetThreadErrorMode if it is available (on Windows 7 and above). |
Date: |
Wed, 17 Mar 2010 22:33:50 +0100 |
User-agent: |
Mutt/1.5.20 (2009-10-28) |
* Peter Rosin wrote on Wed, Mar 17, 2010 at 10:50:40AM CET:
> Hmm, my last argument made me think that it's perhaps not wise for
> libtool to rely on the last error to not change over a successful
> call either. But that potential problem was there before this patch
> too, so I'm proposing a separate patch for that in a followup mail...
Ah, so my comment was not purely hot air, just mostly. ;-)
> So, ok to push this as attached?
Yes, and the followup, too.
Thanks,
Ralf
> 2010-03-17 Peter Rosin <address@hidden>
>
> Use Get/SetThreadErrorMode if they are available.
> * libltdl/loaders/loadlibrary.c (wrap_geterrormode): Replaced...
> (wrap_getthreaderrormode): ...by this function that checks
> first for GetThreadErrorMode, then GetErrorMode and makes use
> of either of those or...
> (fallback_getthreaderrormode): ...else falls back to this
> replacement function that implements the old workaround, which
> was previously implemented in...
> (fallback_geterrormode): ...this now renamed function.
> (geterrormode): Replaced...
> (getthreaderrormode): ...by this function pointer that points
> at either of wrap_getthreaderrormode, GetThreadErrorMode,
> GetErrorMode or fallback_getthreaderrormode.
> (wrap_setthreaderrormode): New function that checks if
> SetThreadErrorMode is supported by the system and makes use of
> it if it is.
> (fallback_setthreaderrormode): New function that is used
> otherwise that implements the old version using SetErrorMode.
> (setthreaderrormode): New function pointer that points at
> either of wrap_setthreaderrormode, SetThreadErrorMode or
> fallback_setthreaderrormode.
> (vm_open): Adjust to the above.