From 5da3b56bc6a85f33be4bcdaa834bcd3742809d99 Mon Sep 17 00:00:00 2001 From: Daniel Lehman Date: Sat, 28 Apr 2018 13:02:08 -0700 Subject: [PATCH] advapi32/tests: Don't call function in assert(). Signed-off-by: Daniel Lehman Signed-off-by: Daniel Lehman --- dlls/advapi32/tests/registry.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/dlls/advapi32/tests/registry.c b/dlls/advapi32/tests/registry.c index 1df117bfbb1..2f7566c3000 100644 --- a/dlls/advapi32/tests/registry.c +++ b/dlls/advapi32/tests/registry.c @@ -175,9 +175,12 @@ static DWORD delete_key( HKEY hkey ) static void setup_main_key(void) { + DWORD ret; + if (!RegOpenKeyA( HKEY_CURRENT_USER, "Software\\Wine\\Test", &hkey_main )) delete_key( hkey_main ); - assert (!RegCreateKeyA( HKEY_CURRENT_USER, "Software\\Wine\\Test", &hkey_main )); + ret = RegCreateKeyA( HKEY_CURRENT_USER, "Software\\Wine\\Test", &hkey_main ); + ok(ret == ERROR_SUCCESS, "expected ERROR_SUCCESS, got %d\n", ret); } static void check_user_privs(void) -- 2.17.0