Piotr Caban : msvcrt: Mark gmtime32 tests with negative argument as broken on win8.

Alexandre Julliard julliard at winehq.org
Wed Feb 20 14:01:14 CST 2013


Module: wine
Branch: master
Commit: 61f82d6d02eb34333de9c45561e47f68fb6f1d6e
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=61f82d6d02eb34333de9c45561e47f68fb6f1d6e

Author: Piotr Caban <piotr at codeweavers.com>
Date:   Wed Feb 20 15:53:24 2013 +0100

msvcrt: Mark gmtime32 tests with negative argument as broken on win8.

---

 dlls/msvcrt/tests/time.c |   11 +++++++----
 1 files changed, 7 insertions(+), 4 deletions(-)

diff --git a/dlls/msvcrt/tests/time.c b/dlls/msvcrt/tests/time.c
index b9bc7f1..30d9fa7 100644
--- a/dlls/msvcrt/tests/time.c
+++ b/dlls/msvcrt/tests/time.c
@@ -109,7 +109,7 @@ static void test_gmtime(void)
 
     gmt = -1;
     gmt_tm = p_gmtime32(&gmt);
-    ok(gmt_tm == NULL, "gmt_tm != NULL\n");
+    ok(gmt_tm==NULL || broken(gmt_tm->tm_year==70 && gmt_tm->tm_sec<0), "gmt_tm != NULL\n");
 
     gmt = valid = 0;
     gmt_tm = p_gmtime32(&gmt);
@@ -181,9 +181,12 @@ static void test_gmtime(void)
     errno = 0;
     gmt = -1;
     err = p_gmtime32_s(&gmt_tm_s, &gmt);
-    ok(err == EINVAL, "err = %d\n", err);
-    ok(errno == EINVAL, "errno = %d\n", errno);
-    ok(gmt_tm_s.tm_year == -1, "tm_year = %d\n", gmt_tm_s.tm_year);
+    ok(gmt_tm_s.tm_year==-1 || broken(gmt_tm_s.tm_year==70 && gmt_tm->tm_sec<0),
+            "tm_year = %d\n", gmt_tm_s.tm_year);
+    if(gmt_tm_s.tm_year == -1) {
+        ok(err==EINVAL, "err = %d\n", err);
+        ok(errno==EINVAL, "errno = %d\n", errno);
+    }
 }
 
 static void test_mktime(void)




More information about the wine-cvs mailing list