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
e688e1c1
Commit
e688e1c1
authored
Aug 09, 2018
by
Michael Stefaniuc
Committed by
Alexandre Julliard
Aug 14, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wnaspi32: Use the ARRAY_SIZE() macro.
Signed-off-by:
Michael Stefaniuc
<
mstefani@winehq.org
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
480236c4
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
aspi.c
dlls/wnaspi32/aspi.c
+3
-3
No files found.
dlls/wnaspi32/aspi.c
View file @
e688e1c1
...
...
@@ -130,7 +130,7 @@ int ASPI_GetNumControllers(void)
ERR
(
"Could not open HKLM
\\
%s
\n
"
,
debugstr_w
(
wDevicemapScsi
));
return
0
;
}
while
(
RegEnumKeyW
(
hkeyScsi
,
i
++
,
wPortName
,
sizeof
(
wPortName
)
/
sizeof
(
wPortName
[
0
]
))
==
ERROR_SUCCESS
)
while
(
RegEnumKeyW
(
hkeyScsi
,
i
++
,
wPortName
,
ARRAY_SIZE
(
wPortName
))
==
ERROR_SUCCESS
)
{
if
(
RegOpenKeyExW
(
hkeyScsi
,
wPortName
,
0
,
KEY_QUERY_VALUE
,
&
hkeyPort
)
==
ERROR_SUCCESS
)
{
...
...
@@ -192,7 +192,7 @@ DWORD ASPI_GetHCforController( int controller )
ERR
(
"Could not open HKLM
\\
%s
\n
"
,
debugstr_w
(
wDevicemapScsi
));
return
0xFFFFFFFF
;
}
while
(
RegEnumKeyW
(
hkeyScsi
,
i
++
,
wPortName
,
sizeof
(
wPortName
)
/
sizeof
(
wPortName
[
0
]
))
==
ERROR_SUCCESS
)
while
(
RegEnumKeyW
(
hkeyScsi
,
i
++
,
wPortName
,
ARRAY_SIZE
(
wPortName
))
==
ERROR_SUCCESS
)
{
if
(
RegOpenKeyExW
(
hkeyScsi
,
wPortName
,
0
,
KEY_QUERY_VALUE
|
KEY_ENUMERATE_SUB_KEYS
,
&
hkeyPort
)
==
ERROR_SUCCESS
)
...
...
@@ -215,7 +215,7 @@ DWORD ASPI_GetHCforController( int controller )
return
0xFFFFFFFF
;
}
if
(
RegEnumKeyW
(
hkeyPort
,
-
num_ha
,
wBusName
,
sizeof
(
wBusName
)
/
sizeof
(
wBusName
[
0
]
))
!=
ERROR_SUCCESS
)
if
(
RegEnumKeyW
(
hkeyPort
,
-
num_ha
,
wBusName
,
ARRAY_SIZE
(
wBusName
))
!=
ERROR_SUCCESS
)
{
ERR
(
"Failed to enumerate keys
\n
"
);
RegCloseKey
(
hkeyPort
);
...
...
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