PATCH: COMDLG32_UpdateCurrentDir (commdlg\filedlgbrowser.c)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Changelog:
* dlls\commdlg\filedlgbrowser.c
Do not change directory if path is invalid

License: X11 / LGPL

Author:
Sander van Leeuwen <sandervl@xs4all.nl>

--- filedlgbrowser.c	Sun Jun  2 13:32:40 2002
+++ filedlgbrowser.cn	Thu Jun 27 09:33:30 2002
@@ -93,9 +93,10 @@
 static void COMDLG32_UpdateCurrentDir(FileOpenDlgInfos *fodInfos)
 {
     char lpstrPath[MAX_PATH];
-    SHGetPathFromIDListA(fodInfos->ShellInfos.pidlAbsCurrent,lpstrPath);
-    SetCurrentDirectoryA(lpstrPath);
-    TRACE("new current folder %s\n", lpstrPath);
+    if(SHGetPathFromIDListA(fodInfos->ShellInfos.pidlAbsCurrent,lpstrPath) == TRUE) {
+        SetCurrentDirectoryA(lpstrPath);
+        TRACE("new current folder %s\n", lpstrPath);
+    }
 }
 
 /* copied from shell32 to avoid linking to it */




[Index of Archives]     [Gimp for Windows]     [Red Hat]     [Samba]     [Yosemite Camping]     [Graphics Cards]     [Wine Home]

  Powered by Linux