Stop shlfileop tests crashing under win98

Dan Kegel dank at kegel.com
Tue Jun 10 07:13:02 CDT 2008


Alistair wrote:
>-    /* try an invalid list, only one null terminator */
>-    init_shfo_tests();
>-    shfo.pFrom = "";
>-    shfo.wFunc = FO_DELETE;
>-    ret = SHFileOperation(&shfo);
>-    ok(ret == ERROR_ACCESS_DENIED, "Expected ERROR_ACCESS_DENIED, got %d\n", ret);
>-    ok(file_exists("test1.txt"), "Expected test1.txt to exist\n");
>+    /* This crashes under win98 */
>+    if(0)
>+    {
>+        /* try an invalid list, only one null terminator */

Hey Allistair,
that paragraph looks like it was buggy - it should have had
test1.txt followed by a single nul and then twice MAXPATH
nonnulls and then a double nul, like the similar tests I fixed in
http://www.winehq.org/pipermail/wine-patches/2008-May/055371.html
As it is, there's no way FO_DELETE could see test1.txt to maybe
delete it.

James, do you agree?

Perhaps you could leave it enabled if you fixed it like the
ones I fixed.  (Or tried to fix; sadly, Alexandre hasn't
committed it yet. Why?)
- Dan



More information about the wine-devel mailing list