mirror of
https://github.com/valinet/ExplorerPatcher.git
synced 2025-02-17 11:08:41 +01:00
Fixing RegCloseKey invalid handle
This commit is contained in:
parent
92f5e9084e
commit
3012ced8ff
@ -723,6 +723,7 @@ static BOOL GUI_Build(HDC hDC, HWND hwnd, POINT pt)
|
||||
if (hKey)
|
||||
{
|
||||
RegCloseKey(hKey);
|
||||
hKey = NULL;
|
||||
RegDeleteKeyExW(
|
||||
HKEY_CURRENT_USER,
|
||||
wcschr(section, L'\\') + 1,
|
||||
@ -799,7 +800,10 @@ static BOOL GUI_Build(HDC hDC, HWND hwnd, POINT pt)
|
||||
}
|
||||
InvalidateRect(hwnd, NULL, FALSE);
|
||||
}
|
||||
RegCloseKey(hKey);
|
||||
if (hKey)
|
||||
{
|
||||
RegCloseKey(hKey);
|
||||
}
|
||||
if (bChoice)
|
||||
{
|
||||
for (unsigned int i = 0; i < numChoices; ++i)
|
||||
|
Loading…
x
Reference in New Issue
Block a user