mirror of
https://github.com/moparisthebest/curl
synced 2024-08-13 17:03:50 -04:00
tests/server/util: fix Windows Unicode build
Always use the ANSI version of FormatMessage as we don't have the curl_multibyte gear available here. Closes https://github.com/curl/curl/pull/3758
This commit is contained in:
parent
20b8df1096
commit
dc0712eea3
@ -150,8 +150,8 @@ void win32_perror(const char *msg)
|
||||
char buf[512];
|
||||
DWORD err = SOCKERRNO;
|
||||
|
||||
if(!FormatMessage(FORMAT_MESSAGE_FROM_SYSTEM, NULL, err,
|
||||
LANG_NEUTRAL, buf, sizeof(buf), NULL))
|
||||
if(!FormatMessageA(FORMAT_MESSAGE_FROM_SYSTEM, NULL, err,
|
||||
LANG_NEUTRAL, buf, sizeof(buf), NULL))
|
||||
msnprintf(buf, sizeof(buf), "Unknown error %lu (%#lx)", err, err);
|
||||
if(msg)
|
||||
fprintf(stderr, "%s: ", msg);
|
||||
|
Loading…
Reference in New Issue
Block a user