[PATCH 0/2] MR1156: Allow a loaded registry key to be loaded multiple times.
From: Santino Mazza <smazza(a)codeweavers.com> --- dlls/advapi32/tests/registry.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/dlls/advapi32/tests/registry.c b/dlls/advapi32/tests/registry.c index 55a8074f1b7..0389eafb830 100644 --- a/dlls/advapi32/tests/registry.c +++ b/dlls/advapi32/tests/registry.c @@ -1557,6 +1557,10 @@ static void test_reg_load_key(void) ret = RegLoadKeyA(HKEY_LOCAL_MACHINE, "Test", "saved_key"); ok(ret == ERROR_SUCCESS, "expected ERROR_SUCCESS, got %ld\n", ret); + /* Test if we can load the same file and key again */ + ret = RegLoadKeyA(HKEY_LOCAL_MACHINE, "Test", "saved_key"); + todo_wine ok(ret == ERROR_SUCCESS, "expected ERROR_SUCCESS, got %ld\n", ret); + set_privileges(SE_RESTORE_NAME, FALSE); ret = RegOpenKeyA(HKEY_LOCAL_MACHINE, "Test", &hkHandle); -- GitLab https://gitlab.winehq.org/wine/wine/-/merge_requests/1156
From: Santino Mazza <smazza(a)codeweavers.com> --- dlls/advapi32/tests/registry.c | 2 +- server/registry.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/dlls/advapi32/tests/registry.c b/dlls/advapi32/tests/registry.c index 0389eafb830..75b36249c93 100644 --- a/dlls/advapi32/tests/registry.c +++ b/dlls/advapi32/tests/registry.c @@ -1559,7 +1559,7 @@ static void test_reg_load_key(void) /* Test if we can load the same file and key again */ ret = RegLoadKeyA(HKEY_LOCAL_MACHINE, "Test", "saved_key"); - todo_wine ok(ret == ERROR_SUCCESS, "expected ERROR_SUCCESS, got %ld\n", ret); + ok(ret == ERROR_SUCCESS, "expected ERROR_SUCCESS, got %ld\n", ret); set_privileges(SE_RESTORE_NAME, FALSE); diff --git a/server/registry.c b/server/registry.c index 96ba18a0a5a..fb0204c787d 100644 --- a/server/registry.c +++ b/server/registry.c @@ -2295,7 +2295,7 @@ DECL_HANDLER(load_registry) if (!(parent = get_hkey_obj( objattr->rootdir, 0 ))) return; } - if ((key = create_key( parent, &name, 0, KEY_WOW64_64KEY, 0, sd ))) + if ((key = create_key( parent, &name, 0, KEY_WOW64_64KEY, OBJ_OPENIF, sd ))) { load_registry( key, req->file ); release_object( key ); -- GitLab https://gitlab.winehq.org/wine/wine/-/merge_requests/1156
Hi, It looks like your patch introduced the new failures shown below. Please investigate and fix them before resubmitting your patch. If they are not new, fixing them anyway would help a lot. Otherwise please ask for the known failures list to be updated. The full results can be found at: https://testbot.winehq.org/JobDetails.pl?Key=125372 Your paranoid android. === debian11 (build log) === Task: Could not create the win32 wineprefix: Failed to disable the crash dialogs: Task: WineTest did not produce the win32 report
What happens if some of the loaded keys / values are deleted before the second call to `RegLoadKey()`? Similarly, if one creates keys / values under the loaded key, do they persist after the second call? -- https://gitlab.winehq.org/wine/wine/-/merge_requests/1156#note_12188
participants (4)
-
Huw Davies (@huw) -
Marvin -
Santino Mazza -
Santino Mazza (@tati1454)