Fix Windows _UNICODE build

Use charset specific variant of GetModuleHandle without relying
on _UNICODE not being defined.
This commit is contained in:
Sebastian Hartte 2020-05-30 00:09:53 +02:00 committed by Paul Knopf
parent f7d70aa581
commit c534d4c1d1

View file

@ -22,7 +22,7 @@ static QString nativeModule;
static void* getExportedFunction(const char* symbolName) {
#ifdef _WIN32
HMODULE library = GetModuleHandle(nativeModule.isNull() || nativeModule.isEmpty() ? nullptr
HMODULE library = GetModuleHandleA(nativeModule.isNull() || nativeModule.isEmpty() ? nullptr
: nativeModule.toLocal8Bit());
FARPROC symbol = GetProcAddress(library, symbolName);
return (void*)symbol;