consistently use TEXT() macro with LoadLibrary() and GetModuleHandle()

cf. bug #5435.
This commit is contained in:
Ozkan Sezer
2021-01-04 01:23:50 +03:00
parent 91a831e2d0
commit 01a2f27679
12 changed files with 15 additions and 15 deletions

View File

@@ -48,7 +48,7 @@ WIN_LoadHIDDLL(void)
return 0; /* already loaded */
}
s_pHIDDLL = LoadLibrary(L"hid.dll");
s_pHIDDLL = LoadLibrary(TEXT("hid.dll"));
if (!s_pHIDDLL) {
return -1;
}

View File

@@ -86,17 +86,17 @@ WIN_LoadXInputDLL(void)
* limitations of that API (no devices at startup, no background input, etc.)
*/
version = (1 << 16) | 4;
s_pXInputDLL = LoadLibrary(L"XInput1_4.dll"); /* 1.4 Ships with Windows 8. */
s_pXInputDLL = LoadLibrary(TEXT("XInput1_4.dll")); /* 1.4 Ships with Windows 8. */
if (!s_pXInputDLL) {
version = (1 << 16) | 3;
s_pXInputDLL = LoadLibrary(L"XInput1_3.dll"); /* 1.3 can be installed as a redistributable component. */
s_pXInputDLL = LoadLibrary(TEXT("XInput1_3.dll")); /* 1.3 can be installed as a redistributable component. */
}
if (!s_pXInputDLL) {
s_pXInputDLL = LoadLibrary(L"bin\\XInput1_3.dll");
s_pXInputDLL = LoadLibrary(TEXT("bin\\XInput1_3.dll"));
}
if (!s_pXInputDLL) {
/* "9.1.0" Ships with Vista and Win7, and is more limited than 1.3+ (e.g. XInputGetStateEx is not available.) */
s_pXInputDLL = LoadLibrary(L"XInput9_1_0.dll");
s_pXInputDLL = LoadLibrary(TEXT("XInput9_1_0.dll"));
}
if (!s_pXInputDLL) {
return -1;