2008/6/18 Vitaly Perov <[EMAIL PROTECTED]>:
> If FOF_MULTIDESTFILES flag is set it's not olny mean that pTo contains
> multiple destination files, it also can contain one folder.
>
> Changelog:
> - shell32: SHFileOperation can move several files into one directory
>

The move operation can already do this.  Why is this patch necessary?
The test you sent in already passes, so this 'fix' is not being tested
at all.


@@ -1425,18 +1425,20 @@ static HRESULT move_files(LPSHFILEOPSTRUCTW
lpFileOp, const FILE_LIST *flFrom, c
     if (!PathFileExistsW(flTo->feFiles[0].szDirectory))
         return ERROR_CANCELLED;

+    fileDest = &flTo->feFiles[0];
+
     if ((lpFileOp->fFlags & FOF_MULTIDESTFILES) &&
-        flFrom->dwNumFiles != flTo->dwNumFiles)
+        flFrom->dwNumFiles != flTo->dwNumFiles  &&
+        !IsAttribDir(fileDest->attributes))

Please keep the style the same.  Use flTo->feFiles[0] just like three
lines above.  Again, you need to add tests for these changes.

-- 
James Hawkins


Reply via email to