At least in some Windows the previous invokation to WritePrivateProfileStringA("section6", NULL, NULL, "winetest.ini") creates the entry HKEY_CURRENT_USER/winetest_name1. It seems that the IniFileMapping is cached somewhere, even if it has been removed from the registry.
Signed-off-by: Carlos Rivera carlos@superkaos.org --- dlls/kernel32/tests/profile.c | 2 ++ 1 file changed, 2 insertions(+)
diff --git a/dlls/kernel32/tests/profile.c b/dlls/kernel32/tests/profile.c index c077f8b35b..5f1f4f0fe7 100644 --- a/dlls/kernel32/tests/profile.c +++ b/dlls/kernel32/tests/profile.c @@ -1567,6 +1567,8 @@ static void test_registry_mapping(void)
ret = RegDeleteKeyA(HKEY_LOCAL_MACHINE, "Software\winetest_name2"); ok(!ret, "got error %u\n", ret); + ret = RegDeleteKeyA(HKEY_CURRENT_USER, "winetest_name1"); + ok(!ret, "got error %u\n", ret); ret = RegDeleteKeyA(mapped_key, ""); ok(!ret, "got error %u\n", ret); RegCloseKey(mapped_key);
Hi,
While running your changed tests, I think I found new failures. Being a bot and all I'm not very good at pattern recognition, so I might be wrong, but could you please double-check?
Full results can be found at: https://testbot.winehq.org/JobDetails.pl?Key=77781
Your paranoid android.
=== debiant (32 bit report) ===
kernel32: profile.c:222: Test succeeded inside todo block: expected ERROR_FILE_NOT_FOUND, got 2
=== debiant (32 bit French report) ===
kernel32: profile.c:222: Test succeeded inside todo block: expected ERROR_FILE_NOT_FOUND, got 2
=== debiant (32 bit Japanese:Japan report) ===
kernel32: profile.c:222: Test succeeded inside todo block: expected ERROR_FILE_NOT_FOUND, got 2
=== debiant (32 bit Chinese:China report) ===
kernel32: profile.c:222: Test succeeded inside todo block: expected ERROR_FILE_NOT_FOUND, got 2
=== debiant (32 bit WoW report) ===
kernel32: profile.c:222: Test succeeded inside todo block: expected ERROR_FILE_NOT_FOUND, got 2
=== debiant (64 bit WoW report) ===
kernel32: profile.c:222: Test succeeded inside todo block: expected ERROR_FILE_NOT_FOUND, got 2
On 8/31/20 4:38 AM, Carlos Rivera wrote:
At least in some Windows the previous invokation to WritePrivateProfileStringA("section6", NULL, NULL, "winetest.ini") creates the entry HKEY_CURRENT_USER/winetest_name1. It seems that the IniFileMapping is cached somewhere, even if it has been removed from the registry.
Signed-off-by: Carlos Rivera carlos@superkaos.org
dlls/kernel32/tests/profile.c | 2 ++ 1 file changed, 2 insertions(+)
diff --git a/dlls/kernel32/tests/profile.c b/dlls/kernel32/tests/profile.c index c077f8b35b..5f1f4f0fe7 100644 --- a/dlls/kernel32/tests/profile.c +++ b/dlls/kernel32/tests/profile.c @@ -1567,6 +1567,8 @@ static void test_registry_mapping(void)
ret = RegDeleteKeyA(HKEY_LOCAL_MACHINE, "Software\\winetest_name2"); ok(!ret, "got error %u\n", ret);
- ret = RegDeleteKeyA(HKEY_CURRENT_USER, "winetest_name1");
- ok(!ret, "got error %u\n", ret); ret = RegDeleteKeyA(mapped_key, ""); ok(!ret, "got error %u\n", ret); RegCloseKey(mapped_key);
Perhaps a better workaround would be to delete the "name1" value from mapping_subkey after running the previous section? That one seems to work for me with Windows 7.