1
0
mirror of https://github.com/wine-mirror/wine synced 2024-07-08 20:06:18 +00:00

setupapi: Recursively remove any subkeys before calling NtDeleteKey().

Signed-off-by: Hugh McMaster <hugh.mcmaster@outlook.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Hugh McMaster 2017-09-12 06:08:13 +00:00 committed by Alexandre Julliard
parent 19d57982ec
commit c9308b8d6b
2 changed files with 5 additions and 2 deletions

View File

@ -320,7 +320,11 @@ static BOOL do_reg_operation( HKEY hkey, const WCHAR *value, INFCONTEXT *context
}
else RegDeleteValueW( hkey, value );
}
else NtDeleteKey( hkey );
else
{
RegDeleteTreeW( hkey, NULL );
NtDeleteKey( hkey );
}
return TRUE;
}

View File

@ -174,7 +174,6 @@ static void test_registry(void)
/* Check if the registry key is recursively deleted */
res = RegOpenKeyA(HKEY_CURRENT_USER, "Software\\Wine\\setupapitest", &key);
todo_wine
ok(res == ERROR_FILE_NOT_FOUND, "Didn't expect the registry key to exist\n");
/* Just in case */
if (res == ERROR_SUCCESS)