Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
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-winehq
Commits
9b1e1b2a
Commit
9b1e1b2a
authored
Sep 21, 2007
by
Juan Lang
Committed by
Alexandre Julliard
Sep 24, 2007
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
setupapi: Set last error on failure in SetupDiOpenClassRegKeyExW.
parent
a9d74cf9
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
23 additions
and
19 deletions
+23
-19
devinst.c
dlls/setupapi/devinst.c
+23
-19
No files found.
dlls/setupapi/devinst.c
View file @
9b1e1b2a
...
...
@@ -2338,8 +2338,9 @@ HKEY WINAPI SetupDiOpenClassRegKeyExW(
PVOID
Reserved
)
{
HKEY
hClassesKey
;
HKEY
hClassK
ey
;
HKEY
k
ey
;
LPCWSTR
lpKeyName
;
LONG
l
;
if
(
MachineName
!=
NULL
)
{
...
...
@@ -2364,15 +2365,16 @@ HKEY WINAPI SetupDiOpenClassRegKeyExW(
if
(
!
ClassGuid
)
{
if
(
RegOpenKeyExW
(
HKEY_LOCAL_MACHINE
,
if
(
(
l
=
RegOpenKeyExW
(
HKEY_LOCAL_MACHINE
,
lpKeyName
,
0
,
samDesired
,
&
hClassesKey
))
&
hClassesKey
))
)
{
return
INVALID_HANDLE_VALUE
;
SetLastError
(
l
);
hClassesKey
=
INVALID_HANDLE_VALUE
;
}
return
hClassesKey
;
key
=
hClassesKey
;
}
else
{
...
...
@@ -2380,28 +2382,30 @@ HKEY WINAPI SetupDiOpenClassRegKeyExW(
SETUPDI_GuidToString
(
ClassGuid
,
bracedGuidString
);
if
(
RegOpenKeyExW
(
HKEY_LOCAL_MACHINE
,
if
(
!
(
l
=
RegOpenKeyExW
(
HKEY_LOCAL_MACHINE
,
lpKeyName
,
0
,
samDesired
,
&
hClassesKey
))
&
hClassesKey
))
)
{
return
INVALID_HANDLE_VALUE
;
if
((
l
=
RegOpenKeyExW
(
hClassesKey
,
bracedGuidString
,
0
,
samDesired
,
&
key
)))
{
SetLastError
(
l
);
key
=
INVALID_HANDLE_VALUE
;
}
RegCloseKey
(
hClassesKey
);
}
if
(
RegOpenKeyExW
(
hClassesKey
,
bracedGuidString
,
0
,
samDesired
,
&
hClassKey
))
else
{
RegCloseKey
(
hClassesKey
);
return
INVALID_HANDLE_VALUE
;
SetLastError
(
l
);
key
=
INVALID_HANDLE_VALUE
;
}
RegCloseKey
(
hClassesKey
);
return
hClassKey
;
}
return
key
;
}
/***********************************************************************
...
...
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