wintrust: Don't close key if RegOpenKeyExW failed.

Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Jacek Caban 2016-10-17 19:32:07 +02:00 committed by Alexandre Julliard
parent a45eb80790
commit fb518192bb
1 changed files with 1 additions and 1 deletions

View File

@ -811,7 +811,7 @@ static FARPROC WINTRUST_ReadProviderFromReg(WCHAR *GuidString, const WCHAR *Func
lstrcatW(ProvKey, GuidString);
Res = RegOpenKeyExW(HKEY_LOCAL_MACHINE, ProvKey, 0, KEY_READ, &Key);
if (Res != ERROR_SUCCESS) goto error_close_key;
if (Res != ERROR_SUCCESS) return NULL;
/* Read the $DLL entry */
Size = sizeof(DllName);