[BROWSEUI_APITEST] Fix abnormal termination on fn2 == NULL
authorKatayama Hirofumi MZ <katayama.hirofumi.mz@gmail.com>
Thu, 4 Mar 2021 05:42:04 +0000 (14:42 +0900)
committerKatayama Hirofumi MZ <katayama.hirofumi.mz@gmail.com>
Thu, 4 Mar 2021 05:42:04 +0000 (14:42 +0900)
The DoWordBreakProc function crashed.
CORE-9281

modules/rostests/apitests/browseui/IAutoComplete.cpp

index 1493818..0fa7d30 100644 (file)
@@ -350,7 +350,10 @@ DoTestCaseA(INT x, INT y, INT cx, INT cy, LPCWSTR pszInput,
             (EDITWORDBREAKPROC)SendMessageW(hwndEdit, EM_GETWORDBREAKPROC, 0, 0);
         ok(fn1 != fn2, "fn1 == fn2\n");
         ok(fn2 != NULL, "fn2 was NULL\n");
-        DoWordBreakProc(fn2);
+        if (fn2)
+            DoWordBreakProc(fn2);
+        else
+            skip("fn2 == NULL\n");
     }
 
     // take care of the message queue