Rob Shearman : advapi32:
Change the test for the type parameter of RegQueryValueExA to only run
on Win9x , since the value is set to a random value on NT.
Alexandre Julliard
julliard at wine.codeweavers.com
Thu Dec 28 07:40:19 CST 2006
Module: wine
Branch: master
Commit: 214eb389c994e52972032a278fde26bbfa460225
URL: http://source.winehq.org/git/wine.git/?a=commit;h=214eb389c994e52972032a278fde26bbfa460225
Author: Rob Shearman <rob at codeweavers.com>
Date: Wed Dec 27 19:14:43 2006 +0000
advapi32: Change the test for the type parameter of RegQueryValueExA to only run on Win9x, since the value is set to a random value on NT.
---
dlls/advapi32/tests/registry.c | 8 ++++++--
1 files changed, 6 insertions(+), 2 deletions(-)
diff --git a/dlls/advapi32/tests/registry.c b/dlls/advapi32/tests/registry.c
index 152c8e7..45756c6 100644
--- a/dlls/advapi32/tests/registry.c
+++ b/dlls/advapi32/tests/registry.c
@@ -345,8 +345,12 @@ static void test_query_value_ex(void)
ret = RegQueryValueExA(HKEY_CLASSES_ROOT, "Nonexistent Value", NULL, &type, NULL, &size);
ok(ret == ERROR_FILE_NOT_FOUND, "expected ERROR_FILE_NOT_FOUND, got %d\n", ret);
ok(size == 0, "size should have been set to 0 instead of %d\n", size);
- ok(type == (DWORD)HKEY_CLASSES_ROOT /* NT */ || type == 0 /* Win9x */,
- "type should have been set to 0x80000000 or 0 instead of 0x%x\n", type);
+ /* the type parameter is cleared on Win9x, but is set to a random value on
+ * NT, so don't do this test there */
+ if (GetVersion() & 0x80000000)
+ ok(type == 0, "type should have been set to 0 instead of 0x%x\n", type);
+ else
+ trace("test_query_value_ex: type set to: 0x%08x\n", type);
size = sizeof(buffer);
ret = RegQueryValueExA(HKEY_CLASSES_ROOT, "Nonexistent Value", NULL, &type, buffer, &size);
More information about the wine-cvs
mailing list