From 148483062882dab3c941ac153d2fc75f7b153552 Mon Sep 17 00:00:00 2001 From: Jon Griffiths Date: Wed, 28 May 2008 06:01:39 -0700 Subject: [PATCH] msvcrt: Fix a test that fails on win95. --- dlls/msvcrt/tests/printf.c | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/dlls/msvcrt/tests/printf.c b/dlls/msvcrt/tests/printf.c index 7e07241f9b8..2cd08a78c7d 100644 --- a/dlls/msvcrt/tests/printf.c +++ b/dlls/msvcrt/tests/printf.c @@ -221,8 +221,15 @@ static void test_sprintf( void ) format = "%I32d"; r = sprintf(buffer,format,1); - ok(!strcmp(buffer,"1"),"I32d failed\n"); - ok( r==1, "return count wrong\n"); + if (r == 1) + { + ok(!strcmp(buffer,"1"),"I32d failed, got '%s'\n",buffer); + } + else + { + /* Older versions don't grok I32 format */ + ok(r == 4 && !strcmp(buffer,"I32d"),"I32d failed, got '%s',%d\n",buffer,r); + } format = "%I64D"; r = sprintf(buffer,format,(LONGLONG)-1);