Paul Vriens : snmpapi/tests: Fix failures on NT4 and below.
Alexandre Julliard
julliard at winehq.org
Wed Nov 12 07:18:48 CST 2008
Module: wine
Branch: master
Commit: ad8efd93400984d121a7d0d30dfc01d58ed41935
URL: http://source.winehq.org/git/wine.git/?a=commit;h=ad8efd93400984d121a7d0d30dfc01d58ed41935
Author: Paul Vriens <Paul.Vriens.Wine at gmail.com>
Date: Wed Nov 12 12:20:11 2008 +0100
snmpapi/tests: Fix failures on NT4 and below.
---
dlls/snmpapi/tests/util.c | 18 ++++++++++++++++--
1 files changed, 16 insertions(+), 2 deletions(-)
diff --git a/dlls/snmpapi/tests/util.c b/dlls/snmpapi/tests/util.c
index 780556c..f8067c2 100644
--- a/dlls/snmpapi/tests/util.c
+++ b/dlls/snmpapi/tests/util.c
@@ -71,6 +71,7 @@ static void test_SnmpUtilOidToA(void)
static AsnObjectIdentifier oid4 = { 258, ids2 };
static AsnObjectIdentifier oid5 = { 1, ids3 };
static const char expect0[] = "<null oid>";
+ static const char expect0_alt[] = "NUL";
static const char expect1[] = "1.3.6.1.4.1.311";
static const char expect2[] =
"1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1."
@@ -90,6 +91,15 @@ static void test_SnmpUtilOidToA(void)
"1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1."
"1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1."
"1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1";
+ static const char expect3_alt[] =
+ "1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1."
+ "1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1."
+ "1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1."
+ "1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1."
+ "1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1."
+ "1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1."
+ "1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1."
+ "1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1.1";
static const char expect4[] = "-1";
/* This crashes under win98 */
@@ -103,7 +113,9 @@ static void test_SnmpUtilOidToA(void)
ret = SnmpUtilOidToA(&oid0);
ok(ret != NULL, "SnmpUtilOidToA failed\n");
- ok(!strcmp(ret, expect0), "SnmpUtilOidToA failed got \n%s\n expected \n%s\n",
+ ok(!strcmp(ret, expect0) ||
+ broken(!strcmp(ret, expect0_alt)), /* Win98, WinMe, NT4 */
+ "SnmpUtilOidToA failed got \n%s\n expected \n%s\n",
ret, expect0);
ret = SnmpUtilOidToA(&oid1);
@@ -123,7 +135,9 @@ static void test_SnmpUtilOidToA(void)
ret = SnmpUtilOidToA(&oid4);
ok(ret != NULL, "SnmpUtilOidToA failed\n");
- ok(!strcmp(ret, expect3), "SnmpUtilOidToA failed got \n%s\n expected \n%s\n",
+ ok(!strcmp(ret, expect3) ||
+ broken(!strcmp(ret, expect3_alt)), /* Win98, WinMe, NT4 */
+ "SnmpUtilOidToA failed got \n%s\n expected \n%s\n",
ret, expect3);
ret = SnmpUtilOidToA(&oid5);
More information about the wine-cvs
mailing list