URLMON: Fix protocol test

Jacek Caban jack at itma.pwr.wroc.pl
Sun Sep 11 10:28:12 CDT 2005


Changelog:
    Fix protocol test
-------------- next part --------------
Index: dlls/urlmon/tests/protocol.c
===================================================================
RCS file: /home/wine/wine/dlls/urlmon/tests/protocol.c,v
retrieving revision 1.2
diff -u -p -r1.2 protocol.c
--- dlls/urlmon/tests/protocol.c	9 Sep 2005 09:09:22 -0000	1.2
+++ dlls/urlmon/tests/protocol.c	11 Sep 2005 15:23:52 -0000
@@ -318,6 +318,7 @@ static void test_file_protocol_url(LPCWS
 static void test_file_protocol(void) {
     IInternetProtocol *protocol;
     WCHAR buf[MAX_PATH];
+    DWORD size;
     ULONG len;
     HANDLE file;
     HRESULT hres;
@@ -332,10 +333,10 @@ static void test_file_protocol(void) {
 
     file = CreateFileW(wszIndexHtml, GENERIC_WRITE, 0, NULL, CREATE_ALWAYS,
             FILE_ATTRIBUTE_NORMAL, NULL);
-    ok(file != NULL, "CreateFile failed\n");
-    if(!file)
+    ok(file != INVALID_HANDLE_VALUE, "CreateFile failed\n");
+    if(file == INVALID_HANDLE_VALUE)
         return;
-    WriteFile(file, html_doc, sizeof(html_doc)-1, NULL, NULL);
+    WriteFile(file, html_doc, sizeof(html_doc)-1, &size, NULL);
     CloseHandle(file);
 
     file_name = wszIndexHtml;


More information about the wine-patches mailing list