Commit 10b2d6db authored by Paul Vriens's avatar Paul Vriens Committed by Alexandre Julliard

shdocvw/tests: Fix test failures on XP SP2 and higher.

parent 49da5031
...@@ -251,9 +251,10 @@ static void test_ParseURLFromOutsideSourceA(void) ...@@ -251,9 +251,10 @@ static void test_ParseURLFromOutsideSourceA(void)
len = maxlen-1; len = maxlen-1;
dummy = 0; dummy = 0;
res = pParseURLFromOutsideSourceA(ParseURL_table[i].url, buffer, &len, &dummy); res = pParseURLFromOutsideSourceA(ParseURL_table[i].url, buffer, &len, &dummy);
ok( res == 0 && len == ParseURL_table[i].len + 1, /* len includes the terminating 0 on XP SP1 and before, when the buffer is too small */
"#%d (-1): got %d and %d (expected '0' and %d)\n", ok( res == 0 && (len == ParseURL_table[i].len || len == ParseURL_table[i].len + 1),
i, res, len, ParseURL_table[i].len + 1); "#%d (-1): got %d and %d (expected '0' and %d or %d)\n",
i, res, len, ParseURL_table[i].len, ParseURL_table[i].len + 1);
memset(buffer, '#', sizeof(buffer)-1); memset(buffer, '#', sizeof(buffer)-1);
buffer[sizeof(buffer)-1] = '\0'; buffer[sizeof(buffer)-1] = '\0';
...@@ -341,9 +342,10 @@ static void test_ParseURLFromOutsideSourceW(void) ...@@ -341,9 +342,10 @@ static void test_ParseURLFromOutsideSourceW(void)
len = maxlen - 1; len = maxlen - 1;
dummy = 0; dummy = 0;
res = pParseURLFromOutsideSourceW(urlW, bufferW, &len, &dummy); res = pParseURLFromOutsideSourceW(urlW, bufferW, &len, &dummy);
ok( res == 0 && len == ParseURL_table[0].len + 1, /* len includes the terminating 0 on XP SP1 and before, when the buffer is too small */
"-1: got %d and %d (expected '0' and %d)\n", ok( res == 0 && (len == ParseURL_table[0].len || len == ParseURL_table[0].len + 1),
res, len, ParseURL_table[0].len + 1); "-1: got %d and %d (expected '0' and %d or %d)\n",
res, len, ParseURL_table[0].len, ParseURL_table[0].len + 1);
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment