Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-cw
Commits
88fa3459
Commit
88fa3459
authored
Mar 17, 2023
by
Sven Baars
Committed by
Alexandre Julliard
Mar 17, 2023
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
kernelbase: Also call NtOpenKeyEx() on empty key names.
Wine-Bug:
https://bugs.winehq.org/show_bug.cgi?id=54691
parent
68920ee4
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
5 deletions
+5
-5
registry.c
dlls/advapi32/tests/registry.c
+2
-2
registry.c
dlls/kernelbase/registry.c
+3
-3
No files found.
dlls/advapi32/tests/registry.c
View file @
88fa3459
...
...
@@ -1510,11 +1510,11 @@ static void test_reg_delete_key(void)
ok
(
ret
==
ERROR_SUCCESS
,
"Could not open key, got %ld
\n
"
,
ret
);
ret
=
RegDeleteKeyExA
(
key
,
""
,
KEY_WOW64_32KEY
,
0
);
todo_wine_if
(
ptr_size
==
64
)
ok
(
ret
==
ERROR_SUCCESS
,
"RegDeleteKeyExA failed, got %ld
\n
"
,
ret
);
ok
(
ret
==
ERROR_SUCCESS
,
"RegDeleteKeyExA failed, got %ld
\n
"
,
ret
);
RegCloseKey
(
key
);
ret
=
RegOpenKeyExA
(
hkey_main
,
"deleteme"
,
0
,
KEY_READ
|
KEY_WOW64_32KEY
,
&
key
);
todo_wine_if
(
ptr_size
==
64
)
ok
(
ret
==
ERROR_FILE_NOT_FOUND
,
"Key was not deleted, got %ld
\n
"
,
ret
);
ok
(
ret
==
ERROR_FILE_NOT_FOUND
,
"Key was not deleted, got %ld
\n
"
,
ret
);
RegCloseKey
(
key
);
}
...
...
dlls/kernelbase/registry.c
View file @
88fa3459
...
...
@@ -155,7 +155,7 @@ static NTSTATUS open_subkey( HKEY *subkey, HKEY root, UNICODE_STRING *name, DWOR
attr
.
SecurityDescriptor
=
NULL
;
attr
.
SecurityQualityOfService
=
NULL
;
if
(
buffer
[
0
]
==
'\\'
)
return
STATUS_OBJECT_PATH_INVALID
;
if
(
len
>
0
&&
buffer
[
0
]
==
'\\'
)
return
STATUS_OBJECT_PATH_INVALID
;
while
(
i
<
len
&&
buffer
[
i
]
!=
'\\'
)
i
++
;
str
.
Buffer
=
name
->
Buffer
;
...
...
@@ -202,7 +202,7 @@ static NTSTATUS open_subkey( HKEY *subkey, HKEY root, UNICODE_STRING *name, DWOR
/* wrapper for NtOpenKeyEx to handle Wow6432 nodes */
static
NTSTATUS
open_key
(
HKEY
*
retkey
,
HKEY
root
,
UNICODE_STRING
name
,
DWORD
options
,
ACCESS_MASK
access
)
{
HKEY
subkey
,
subkey_root
=
root
;
HKEY
subkey
=
0
,
subkey_root
=
root
;
NTSTATUS
status
=
0
;
*
retkey
=
NULL
;
...
...
@@ -228,7 +228,7 @@ static NTSTATUS open_key( HKEY *retkey, HKEY root, UNICODE_STRING name, DWORD op
return
status
;
}
while
(
!
status
&&
name
.
Length
)
while
(
!
status
&&
(
name
.
Length
||
!
subkey
)
)
{
status
=
open_subkey
(
&
subkey
,
subkey_root
,
&
name
,
options
,
access
);
if
(
subkey_root
&&
subkey_root
!=
root
)
NtClose
(
subkey_root
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment