http://bugs.winehq.org/show_bug.cgi?id=27178
Summary: advapi32: CryptEnumProvidersW may don't free resources Product: Wine Version: unspecified Platform: x86 OS/Version: Linux Status: UNCONFIRMED Severity: normal Priority: P2 Component: advapi32 AssignedTo: wine-bugs@winehq.org ReportedBy: menone7@gmail.com
CryptEnumProvidersW may don't free resources, if something was wrong with the type registration.
if (RegOpenKeyW(hKey, pszProvName, &subkey)) return FALSE; if (RegQueryValueExW(subkey, typeW, NULL, NULL, (BYTE*)pdwProvType, &size)) return FALSE;
must be
if (RegOpenKeyW(hKey, pszProvName, &subkey)) { RegCloseKey(hKey); SetLastError(NTE_FAIL); return FALSE; } if (RegQueryValueExW(subkey, typeW, NULL, NULL, (BYTE*)pdwProvType, &size)) { RegCloseKey(subkey); RegCloseKey(hKey); SetLastError(NTE_FAIL); return FALSE; }