|author||wm4 <wm4@nowhere>||2015-07-30 21:50:11 +0200|
|committer||wm4 <wm4@nowhere>||2015-07-30 21:50:11 +0200|
win32: more wchar_t -> WCHAR replacements
This was essentially missing from commit 0b52ac8a. Since L"..." string literals have the type wchar_t, we can't use them for UTF-16 strings. Use C11 u"..." string literals instead. These have the type char16_t, but we simply assume char16_t is the same underlying type as WCHAR. In practice, they're both unsigned short. For this reason use -std=c11 on Windows. Since Windows is a "special" environment (we require either MinGW or Cygwin), we don't need to worry too much about compiler compatibility.
Diffstat (limited to 'stream/stream_file.c')
1 files changed, 1 insertions, 1 deletions
diff --git a/stream/stream_file.c b/stream/stream_file.c
index 527261edd7..114b1d4eb8 100644
@@ -198,7 +198,7 @@ static bool check_stream_network(int fd)
// NtQueryVolumeInformationFile is an internal Windows function. It has
// been present since Windows XP, however this code should fail gracefully
// if it's removed from a future version of Windows.
- HMODULE ntdll = GetModuleHandleW(L"ntdll.dll");
+ HMODULE ntdll = GetModuleHandleW(u"ntdll.dll");
pNtQueryVolumeInformationFile = (NTSTATUS (NTAPI*)(HANDLE,
PIO_STATUS_BLOCK, PVOID, ULONG, FS_INFORMATION_CLASS))