Commit bf1b965e authored by Paul Vriens's avatar Paul Vriens Committed by Alexandre Julliard

wininet/tests: Fix a test failure on IE8.

parent 2d1f55cc
...@@ -1162,13 +1162,20 @@ static void test_http_cache(void) ...@@ -1162,13 +1162,20 @@ static void test_http_cache(void)
ok(ret, "HttpSendRequest failed: %u\n", GetLastError()); ok(ret, "HttpSendRequest failed: %u\n", GetLastError());
size = sizeof(file_name); size = sizeof(file_name);
file_name[0] = 0;
ret = InternetQueryOptionA(request, INTERNET_OPTION_DATAFILE_NAME, file_name, &size); ret = InternetQueryOptionA(request, INTERNET_OPTION_DATAFILE_NAME, file_name, &size);
ok(ret, "InternetQueryOptionA(INTERNET_OPTION_DATAFILE_NAME) failed %u\n", GetLastError()); if (ret)
{
file = CreateFile(file_name, GENERIC_READ, FILE_SHARE_READ|FILE_SHARE_WRITE, NULL, OPEN_EXISTING, file = CreateFile(file_name, GENERIC_READ, FILE_SHARE_READ|FILE_SHARE_WRITE, NULL, OPEN_EXISTING,
FILE_ATTRIBUTE_NORMAL, NULL); FILE_ATTRIBUTE_NORMAL, NULL);
ok(file != INVALID_HANDLE_VALUE, "Could not create file: %u\n", GetLastError()); ok(file != INVALID_HANDLE_VALUE, "Could not create file: %u\n", GetLastError());
CloseHandle(file); CloseHandle(file);
}
else
{
/* < IE8 */
ok(file_name[0] == 0, "Didn't expect a file name\n");
}
ok(InternetCloseHandle(request), "Close request handle failed\n"); ok(InternetCloseHandle(request), "Close request handle failed\n");
ok(InternetCloseHandle(connect), "Close connect handle failed\n"); ok(InternetCloseHandle(connect), "Close connect handle failed\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