Fix the last two remaining shell32 test failures on win98.

Rolf Kalbermatter rolf.kalbermatter at citeng.com
Fri Sep 19 08:27:35 CDT 2003


Changelog
  - dlls/shell32/tests/shlfileop.c
    Fix the last two remaining shell32 test failures on win98.

Rolf Kalbermatter

Index: dlls/shell32/tests/shlfileop.c
===================================================================
RCS file: /home/wine/wine/dlls/shell32/tests/shlfileop.c,v
retrieving revision 1.9
diff -u -r1.9 shlfileop.c
--- dlls/shell32/tests/shlfileop.c	5 Sep 2003 23:08:30 -0000	1.9
+++ dlls/shell32/tests/shlfileop.c	19 Sep 2003 13:22:48 -0000
@@ -153,6 +153,7 @@
     SHFILEOPSTRUCTA shfo, shfo2;
     CHAR from[MAX_PATH];
     CHAR to[MAX_PATH];
+    DWORD retval;
 
     shfo.hwnd = NULL;
     shfo.wFunc = FO_RENAME;
@@ -175,7 +176,8 @@
 
     set_curr_dir_path(from, "test1.txt\0test2.txt\0test4.txt\0");
     set_curr_dir_path(to, "test6.txt\0test7.txt\0test8.txt\0");
-    ok(SHFileOperationA(&shfo), "Can't rename many files");
+    retval = SHFileOperationA(&shfo); /* W98 returns 0, W2K and newer returns 0x1F, both do nothing */
+    ok(!retval || retval == 0x1F, "Can't rename many files"); /* W98 returns 0 */
     ok(file_exists(".\\test1.txt"), "The file is not renamed - many files are specified ");
 
     memcpy(&shfo2, &shfo, sizeof(SHFILEOPSTRUCTA));
@@ -183,7 +185,8 @@
 
     set_curr_dir_path(from, "test1.txt\0test2.txt\0test4.txt\0");
     set_curr_dir_path(to, "test6.txt\0test7.txt\0test8.txt\0");
-    ok(SHFileOperationA(&shfo2), "Can't rename many files");
+    retval = SHFileOperationA(&shfo2); /* W98 returns 0, W2K and newer returns 0x1F, both do nothing */
+    ok(!retval || retval == 0x1F, "Can't rename many files");
     ok(file_exists(".\\test1.txt"), "The file is not renamed - many files are specified ");
 
     set_curr_dir_path(from, "test1.txt\0");





More information about the wine-patches mailing list