diff options
author | Bruno Haible <bruno@clisp.org> | 2020-05-30 11:04:02 +0200 |
---|---|---|
committer | Bruno Haible <bruno@clisp.org> | 2020-05-30 11:04:02 +0200 |
commit | 57f80070ccd8461a224cc84b255844539ab72a8d (patch) | |
tree | 2f22eed44e3690bdaa660c6b1fe7322ef6063c69 /lib/write.c | |
parent | 4bc0be55d618e5b276f12f3a9cf8ef37ed0529f5 (diff) | |
download | gnulib-57f80070ccd8461a224cc84b255844539ab72a8d.tar.gz |
Don't assume that UNICODE is not defined.
Many Windows API functions are defined differently (redirecting to a
function with suffix 'W') if the application defines the macro UNICODE
than by default (redirecting to a function with suffix 'A').
* lib/clean-temp.c (OSVERSIONINFO, GetVersionEx): Redirect to the
variant with suffix 'A'.
* lib/dirent-private.h (WIN32_FIND_DATA): Likewise.
* lib/gc-gnulib.c (CryptAcquireContext): Likewise.
* lib/getaddrinfo.c (GetModuleHandle): Likewise.
* lib/getlogin.c (GetUserName): Likewise.
* lib/getlogin_r.c (GetUserName): Likewise.
* lib/gettimeofday.c (LoadLibrary): Likewise.
* lib/isatty.c (LoadLibrary, QueryFullProcessImageName): Likewise.
* lib/link.c (GetModuleHandle, CreateHardLink): Likewise.
* lib/localename.c (GetLocaleInfo, EnumSystemLocales): Likewise.
* lib/mountlist.c (GetDriveType): Likewise.
* lib/nonblocking.c (GetNamedPipeHandleState): Likewise.
* lib/opendir.c (WIN32_FIND_DATA, GetFullPathName, FindFirstFile):
Likewise.
* lib/physmem.c (GetModuleHandle): Likewise.
* lib/poll.c (GetModuleHandle, PeekConsoleInput, CreateEvent,
PeekMessage, DispatchMessage): Likewise.
* lib/progreloc.c (GetModuleFileName): Likewise.
* lib/putenv.c (SetEnvironmentVariable): Likewise.
* lib/read.c (GetNamedPipeHandleState): Likewise.
* lib/readdir.c (FindNextFile): Likewise.
* lib/relocatable.c (GetModuleFileName): Likewise.
* lib/rename.c (MoveFileEx): Likewise.
* lib/rewinddir.c (FindFirstFile): Likewise.
* lib/select.c (GetModuleHandle, PeekConsoleInput, CreateEvent,
PeekMessage, DispatchMessage): Likewise.
* lib/sethostname.c (GetComputerNameEx, SetComputerNameEx): Likewise.
* lib/socket.c (WSASocket): Likewise.
* lib/stat-w32.c (LoadLibrary, GetFinalPathNameByHandle): Likewise.
* lib/stat.c (WIN32_FIND_DATA, CreateFile, FindFirstFile): Likewise.
* lib/stdio-read.c (GetNamedPipeHandleState): Likewise.
* lib/stdio-write.c (GetNamedPipeHandleState): Likewise.
* lib/tmpdir.c (GetTempPath): Likewise.
* lib/tmpfile.c (OSVERSIONINFO, GetVersionEx, GetTempPath): Likewise.
* lib/uname.c (OSVERSIONINFO, GetVersionEx): Likewise.
* lib/utime.c (CreateFile, GetFileAttributes): Likewise.
* lib/windows-cond.c (CreateEvent): Likewise.
* lib/windows-rwlock.c (CreateEvent): Likewise.
* lib/windows-timedmutex.c (CreateEvent): Likewise.
* lib/windows-timedrecmutex.c (CreateEvent): Likewise.
* lib/windows-timedrwlock.c (CreateEvent): Likewise.
* lib/write.c (GetNamedPipeHandleState): Likewise.
Diffstat (limited to 'lib/write.c')
-rw-r--r-- | lib/write.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/write.c b/lib/write.c index a3912838cd..581e674b40 100644 --- a/lib/write.c +++ b/lib/write.c @@ -43,6 +43,10 @@ # include <io.h> # endif +/* Don't assume that UNICODE is not defined. */ +# undef GetNamedPipeHandleState +# define GetNamedPipeHandleState GetNamedPipeHandleStateA + # undef write # if HAVE_MSVC_INVALID_PARAMETER_HANDLER |