setupapi: Use sizeof() instead of numerical constants for buffer sizes.

Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Nikolay Sivov 2017-02-08 15:11:42 +03:00 committed by Alexandre Julliard
parent 0bfb97dcba
commit 01080e6750
1 changed files with 2 additions and 2 deletions

View File

@ -903,7 +903,7 @@ BOOL WINAPI SetupDiClassGuidsFromNameExW(
for (dwIndex = 0; ; dwIndex++)
{
dwLength = 40;
dwLength = sizeof(szKeyName) / sizeof(WCHAR);
lError = RegEnumKeyExW(hClassesKey,
dwIndex,
szKeyName,
@ -927,7 +927,7 @@ BOOL WINAPI SetupDiClassGuidsFromNameExW(
return FALSE;
}
dwLength = 256 * sizeof(WCHAR);
dwLength = sizeof(szClassName);
if (!RegQueryValueExW(hClassKey,
Class,
NULL,