[PATCH] msvideo.dll16: Use the ARRAY_SIZE() macro

Michael Stefaniuc mstefani at winehq.org
Wed Jul 25 17:05:56 CDT 2018


Signed-off-by: Michael Stefaniuc <mstefani at winehq.org>
---
 dlls/msvideo.dll16/msvideo16.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/dlls/msvideo.dll16/msvideo16.c b/dlls/msvideo.dll16/msvideo16.c
index d390020ecc..bc239a8ab3 100644
--- a/dlls/msvideo.dll16/msvideo16.c
+++ b/dlls/msvideo.dll16/msvideo16.c
@@ -889,7 +889,7 @@ DWORD WINAPI VideoCapDriverDescAndVer16(WORD nr, LPSTR buf1, WORD buf1len,
 	RegQueryInfoKeyA( hKey, 0, 0, 0, &cnt, 0, 0, 0, 0, 0, 0, 0);
 	for (i = 0; i < cnt; i++)
 	{
-	    bufLen = sizeof(buf) / sizeof(buf[0]);
+            bufLen = ARRAY_SIZE(buf);
 	    lRet = RegEnumKeyExA(hKey, i, buf, &bufLen, 0, 0, 0, &lastWrite);
 	    if (lRet != ERROR_SUCCESS) continue;
 	    if (strncasecmp(buf, "vid", 3)) continue;
-- 
2.14.4




More information about the wine-devel mailing list