Fix building on win32 if _UNICODE is defined

Explicitly use LoadLibraryA() instead of the LoadLibrary() macro, which 
may expand to LoadLibraryW() depending on build configuration.
This commit is contained in:
Václav Slavík 2017-06-25 17:38:11 +02:00 committed by GitHub
parent 6dc3273aa5
commit 95b95032f9

View File

@ -749,7 +749,7 @@ typedef BOOLEAN (APIENTRY *RTLGENRANDOM_FUNC)(PVOID, ULONG);
static int
writeRandomBytes_RtlGenRandom(void * target, size_t count) {
int success = 0; /* full count bytes written? */
const HMODULE advapi32 = LoadLibrary("ADVAPI32.DLL");
const HMODULE advapi32 = LoadLibraryA("ADVAPI32.DLL");
if (advapi32) {
const RTLGENRANDOM_FUNC RtlGenRandom