diff options
author | David Majnemer <david.majnemer@gmail.com> | 2013-10-07 09:52:36 +0000 |
---|---|---|
committer | David Majnemer <david.majnemer@gmail.com> | 2013-10-07 09:52:36 +0000 |
commit | ae06a63be5a1279739e0c8a2006e72f4bc687d57 (patch) | |
tree | 636622c31be132769d0c843fb4cd9ce516e8399e /lib/Support/Windows/Signals.inc | |
parent | c84c742eddc0c57c34271471f332c9857d79e672 (diff) | |
download | external_llvm-ae06a63be5a1279739e0c8a2006e72f4bc687d57.zip external_llvm-ae06a63be5a1279739e0c8a2006e72f4bc687d57.tar.gz external_llvm-ae06a63be5a1279739e0c8a2006e72f4bc687d57.tar.bz2 |
Windows: Be more explicit with Win32 APIs
This addresses several issues in a similar vein:
- Use the Unicode APIs when possible, running nm on clang shows that we
only use Unicode APIs except for FormatMessage, CreateSemaphore, and
GetModuleHandle. AFAICT, the latter two are coming from MinGW and
not LLVM itself.
- Make getMainExecutable more resilient. It previously considered
return values of zero from ::GetModuleFileNameA to be acceptable.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192096 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Support/Windows/Signals.inc')
-rw-r--r-- | lib/Support/Windows/Signals.inc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/Support/Windows/Signals.inc b/lib/Support/Windows/Signals.inc index 2b4a66d..4b40d51 100644 --- a/lib/Support/Windows/Signals.inc +++ b/lib/Support/Windows/Signals.inc @@ -135,7 +135,7 @@ typedef PVOID (WINAPI *fpSymFunctionTableAccess64)(HANDLE, DWORD64); static fpSymFunctionTableAccess64 SymFunctionTableAccess64; static bool load64BitDebugHelp(void) { - HMODULE hLib = ::LoadLibrary(TEXT("Dbghelp.dll")); + HMODULE hLib = ::LoadLibraryW(L"Dbghelp.dll"); if (hLib) { StackWalk64 = (fpStackWalk64) ::GetProcAddress(hLib, "StackWalk64"); |