Commit bf8ca52a authored by Paul Vriens's avatar Paul Vriens Committed by Alexandre Julliard

advapi32/tests: Fix valgrind warning.

parent a9c3d6f2
...@@ -882,7 +882,7 @@ static void test_query_svc(void) ...@@ -882,7 +882,7 @@ static void test_query_svc(void)
/* Only info level is correct. It looks like the buffer/size is checked second */ /* Only info level is correct. It looks like the buffer/size is checked second */
SetLastError(0xdeadbeef); SetLastError(0xdeadbeef);
ret = pQueryServiceStatusEx(NULL, 0, NULL, 0, &needed); ret = pQueryServiceStatusEx(NULL, 0, NULL, 0, &needed);
/* NT4 checks the handle first */ /* NT4 and Wine check the handle first */
if (GetLastError() != ERROR_INVALID_HANDLE) if (GetLastError() != ERROR_INVALID_HANDLE)
{ {
ok(!ret, "Expected failure\n"); ok(!ret, "Expected failure\n");
...@@ -893,7 +893,7 @@ static void test_query_svc(void) ...@@ -893,7 +893,7 @@ static void test_query_svc(void)
} }
/* Pass a correct buffer and buffersize but a NULL handle */ /* Pass a correct buffer and buffersize but a NULL handle */
statusproc = HeapAlloc(GetProcessHeap(), 0, needed); statusproc = HeapAlloc(GetProcessHeap(), 0, sizeof(SERVICE_STATUS_PROCESS));
bufsize = needed; bufsize = needed;
SetLastError(0xdeadbeef); SetLastError(0xdeadbeef);
ret = pQueryServiceStatusEx(NULL, 0, (BYTE*)statusproc, bufsize, &needed); ret = pQueryServiceStatusEx(NULL, 0, (BYTE*)statusproc, bufsize, &needed);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment