[WIN32NT_APITEST] Do not assert on a driver without DirectX support.
authorMark Jansen <mark.jansen@reactos.org>
Sun, 11 Jun 2017 11:47:41 +0000 (11:47 +0000)
committerMark Jansen <mark.jansen@reactos.org>
Sun, 11 Jun 2017 11:47:41 +0000 (11:47 +0000)
svn path=/trunk/; revision=75001

rostests/apitests/win32nt/ntdd/NtGdiDdQueryDirectDrawObject.c

index ec325b4..07961e9 100644 (file)
@@ -68,7 +68,12 @@ START_TEST(NtGdiDdQueryDirectDrawObject)
 
     /* Create ReactX handle */
     hDirectDraw = (HANDLE) NtGdiDdCreateDirectDrawObject(hdc);
-    ASSERT(hDirectDraw != NULL);
+    RTEST(hDirectDraw != NULL);
+    if (hDirectDraw == NULL)
+    {
+        DeleteDC(hdc);
+        return;
+    }
 
     /* Start Test ReactX NtGdiDdQueryDirectDrawObject function */