Commit 027236b0 authored by Juan Lang's avatar Juan Lang Committed by Alexandre Julliard

crypt32: Don't release default crypto provider on process shutdown.

parent 14a12b88
...@@ -47,7 +47,10 @@ BOOL WINAPI DllMain(HINSTANCE hInstance, DWORD fdwReason, PVOID pvReserved) ...@@ -47,7 +47,10 @@ BOOL WINAPI DllMain(HINSTANCE hInstance, DWORD fdwReason, PVOID pvReserved)
crypt_sip_free(); crypt_sip_free();
root_store_free(); root_store_free();
default_chain_engine_free(); default_chain_engine_free();
if (hDefProv) CryptReleaseContext(hDefProv, 0); /* Don't release the default provider on process shutdown, there's
* no guarantee the provider dll hasn't already been unloaded.
*/
if (hDefProv && !pvReserved) CryptReleaseContext(hDefProv, 0);
break; break;
} }
return TRUE; return TRUE;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment