https://git.reactos.org/?p=reactos.git;a=commitdiff;h=828a65f470ec5b1504b0776bac182d051b855473

commit 828a65f470ec5b1504b0776bac182d051b855473
Author:     Katayama Hirofumi MZ <[email protected]>
AuthorDate: Thu Oct 1 05:03:34 2020 +0900
Commit:     Katayama Hirofumi MZ <[email protected]>
CommitDate: Thu Oct 1 05:03:34 2020 +0900

    [BROWSEUI_APITEST] Follow-up of #3249 (b1c3329)
    
    CORE-9281
---
 modules/rostests/apitests/browseui/IACLCustomMRU.cpp | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/modules/rostests/apitests/browseui/IACLCustomMRU.cpp 
b/modules/rostests/apitests/browseui/IACLCustomMRU.cpp
index cfde9d11cfc..89eb058261d 100644
--- a/modules/rostests/apitests/browseui/IACLCustomMRU.cpp
+++ b/modules/rostests/apitests/browseui/IACLCustomMRU.cpp
@@ -411,8 +411,12 @@ RestoreTypedURLs(const CStringW& url1, const CStringW& 
url2)
     key.Open(HKEY_CURRENT_USER, TYPED_URLS_KEY, KEY_WRITE);
     if (url1 != L"")
         key.SetStringValue(L"url1", url1);
+    else
+        key.DeleteValue(L"url1");
     if (url2 != L"")
         key.SetStringValue(L"url2", url2);
+    else
+        key.DeleteValue(L"url2");
 }
 
 static void
@@ -421,7 +425,7 @@ test_IACLCustomMRU_TypedURLs() // TypedURLs is special case
     CStringW url1, url2; // Save values
     {
         CRegKey key;
-        key.Open(HKEY_CURRENT_USER, TYPED_URLS_KEY, KEY_READ | KEY_WRITE);
+        key.Create(HKEY_CURRENT_USER, TYPED_URLS_KEY);
 
         WCHAR Value[MAX_PATH];
         ULONG cch = _countof(Value);

Reply via email to