PATCH: COMDLG32_UpdateCurrentDir (commdlg\filedlgbrowser.c)
Sander van Leeuwen
sandervl at xs4all.nl
Thu Jun 27 02:37:13 CDT 2002
Changelog:
* dlls\commdlg\filedlgbrowser.c
Do not change directory if path is invalid
License: X11 / LGPL
Author:
Sander van Leeuwen <sandervl at 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 */
More information about the wine-patches
mailing list