setupapi: Don't bother to free libraries at process exit.

This commit is contained in:
Alexandre Julliard 2013-05-17 12:24:41 +02:00
parent cbb2792e01
commit 2aa3d2b0e1
1 changed files with 2 additions and 9 deletions

View File

@ -114,14 +114,6 @@ static BOOL LoadCABINETDll(void)
return TRUE;
}
static void UnloadCABINETDll(void)
{
if (CABINET_hInstance) {
FreeLibrary(CABINET_hInstance);
CABINET_hInstance = 0;
}
}
/* FDICreate callbacks */
static void * CDECL sc_cb_alloc(ULONG cb)
@ -701,7 +693,8 @@ BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved)
SETUPAPI_hInstance = hinstDLL;
break;
case DLL_PROCESS_DETACH:
UnloadCABINETDll();
if (lpvReserved) break;
if (CABINET_hInstance) FreeLibrary(CABINET_hInstance);
break;
}