Commit 2266219c authored by Paul Vriens's avatar Paul Vriens Committed by Alexandre Julliard

wininet/tests: Don't crash on systems with IE5.

parent c01d0ade
......@@ -305,13 +305,19 @@ static void InternetCrackUrlW_test(void)
return;
}
ok( !r, "InternetCrackUrlW succeeded unexpectedly\n");
ok( error == ERROR_INVALID_PARAMETER, "expected ERROR_INVALID_PARAMETER got %u\n", error);
ok( error == ERROR_INVALID_PARAMETER ||
broken(error == ERROR_INTERNET_UNRECOGNIZED_SCHEME), /* IE5 */
"expected ERROR_INVALID_PARAMETER got %u\n", error);
SetLastError(0xdeadbeef);
r = InternetCrackUrlW(url, 0, 0, NULL );
error = GetLastError();
ok( !r, "InternetCrackUrlW succeeded unexpectedly\n");
ok( error == ERROR_INVALID_PARAMETER, "expected ERROR_INVALID_PARAMETER got %u\n", error);
if (error == ERROR_INVALID_PARAMETER)
{
/* Crashes on IE5 */
SetLastError(0xdeadbeef);
r = InternetCrackUrlW(url, 0, 0, NULL );
error = GetLastError();
ok( !r, "InternetCrackUrlW succeeded unexpectedly\n");
ok( error == ERROR_INVALID_PARAMETER, "expected ERROR_INVALID_PARAMETER got %u\n", error);
}
r = InternetCrackUrlW(url, 0, 0, &comp );
ok( r, "failed to crack url\n");
......
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