Windows: Don't bother with pinning Kernel32.dll

We don't delay load it so it shouldn't be going anywhere.

llvm-svn: 192561
This commit is contained in:
David Majnemer 2013-10-14 00:06:58 +00:00
parent d46d6dea68
commit 7af18578f8
1 changed files with 1 additions and 3 deletions

View File

@ -48,9 +48,7 @@ static bool loadSRW() {
if (!sChecked) {
sChecked = true;
HMODULE hLib;
::GetModuleHandleExW(GET_MODULE_HANDLE_EX_FLAG_PIN, L"Kernel32.dll", &hLib);
if (hLib) {
if (HMODULE hLib = ::GetModuleHandleW(L"Kernel32.dll")) {
fpInitializeSRWLock =
(VOID (WINAPI *)(PSRWLOCK))::GetProcAddress(hLib,
"InitializeSRWLock");