https://git.reactos.org/?p=reactos.git;a=commitdiff;h=afbc446ec7ef81d50f30a…
commit afbc446ec7ef81d50f30a5d233c074dfc4213f66
Author: Timo Kreuzer <timo.kreuzer(a)reactos.org>
AuthorDate: Sun Dec 25 09:15:46 2022 +0100
Commit: Timo Kreuzer <timo.kreuzer(a)reactos.org>
CommitDate: Fri Dec 30 11:19:26 2022 +0100
[WIN32NT_APITEST] Fix entirely broken win32knt_apitest NtGdiDdQueryDirectDrawObject
---
.../apitests/win32nt/ntdd/NtGdiDdQueryDirectDrawObject.c | 12 ++----------
1 file changed, 2 insertions(+), 10 deletions(-)
diff --git a/modules/rostests/apitests/win32nt/ntdd/NtGdiDdQueryDirectDrawObject.c
b/modules/rostests/apitests/win32nt/ntdd/NtGdiDdQueryDirectDrawObject.c
index 0f9bc623f31..4eeffc81c4e 100644
--- a/modules/rostests/apitests/win32nt/ntdd/NtGdiDdQueryDirectDrawObject.c
+++ b/modules/rostests/apitests/win32nt/ntdd/NtGdiDdQueryDirectDrawObject.c
@@ -450,7 +450,7 @@ START_TEST(NtGdiDdQueryDirectDrawObject)
RtlZeroMemory(pHalInfo,sizeof(DD_HALINFO));
RtlZeroMemory(pCallBackFlags,sizeof(DWORD)*3);
RtlZeroMemory(puD3dCallbacks,sizeof(D3DNTHAL_CALLBACKS));
- RtlZeroMemory(puD3dDriverData,sizeof(D3DNTHAL_CALLBACKS));
+ RtlZeroMemory(puD3dDriverData,sizeof(D3DNTHAL_GLOBALDRIVERDATA));
RTEST(NtGdiDdQueryDirectDrawObject( hDirectDraw, pHalInfo,
pCallBackFlags, puD3dCallbacks,
@@ -570,6 +570,7 @@ START_TEST(NtGdiDdQueryDirectDrawObject)
if (puD3dDriverData->dwNumTextureFormats != 0)
{
puD3dTextureFormats = malloc (puD3dDriverData->dwNumTextureFormats *
sizeof(DDSURFACEDESC2));
+ ASSERT(puD3dTextureFormats != NULL);
}
RtlZeroMemory(pHalInfo,sizeof(DD_HALINFO));
@@ -600,9 +601,6 @@ START_TEST(NtGdiDdQueryDirectDrawObject)
RTEST(puD3dBufferCallbacks != NULL);
ASSERT(puD3dDriverData != NULL);
- RTEST(puD3dTextureFormats != NULL);
- ASSERT(puD3dTextureFormats != NULL);
-
RTEST(puNumFourCC == NULL);
RTEST(puFourCC == NULL);
RTEST(puNumHeaps == NULL);
@@ -698,9 +696,6 @@ START_TEST(NtGdiDdQueryDirectDrawObject)
RTEST(puD3dBufferCallbacks != NULL);
ASSERT(puD3dDriverData != NULL);
- RTEST(puD3dTextureFormats != NULL);
- ASSERT(puD3dTextureFormats != NULL);
-
RTEST(puNumHeaps != NULL);
ASSERT(puNumHeaps != NULL);
RTEST(NumHeaps == 0);
@@ -764,9 +759,6 @@ START_TEST(NtGdiDdQueryDirectDrawObject)
RTEST(puD3dBufferCallbacks != NULL);
ASSERT(puD3dDriverData != NULL);
- RTEST(puD3dTextureFormats != NULL);
- ASSERT(puD3dTextureFormats != NULL);
-
RTEST(puNumHeaps != NULL);
ASSERT(puNumHeaps != NULL);
RTEST(NumHeaps == 0);