Do not change directory if path is invalid.
This commit is contained in:
parent
886bdb0dbc
commit
2021de684e
|
@ -93,10 +93,11 @@ extern HRESULT SendCustomDlgNotificationMessage(HWND hwndParentDlg, UINT uCode);
|
|||
static void COMDLG32_UpdateCurrentDir(FileOpenDlgInfos *fodInfos)
|
||||
{
|
||||
char lpstrPath[MAX_PATH];
|
||||
SHGetPathFromIDListA(fodInfos->ShellInfos.pidlAbsCurrent,lpstrPath);
|
||||
if(SHGetPathFromIDListA(fodInfos->ShellInfos.pidlAbsCurrent,lpstrPath)) {
|
||||
SetCurrentDirectoryA(lpstrPath);
|
||||
TRACE("new current folder %s\n", lpstrPath);
|
||||
}
|
||||
}
|
||||
|
||||
/* copied from shell32 to avoid linking to it */
|
||||
static HRESULT COMDLG32_StrRetToStrNW (LPVOID dest, DWORD len, LPSTRRET src, LPITEMIDLIST pidl)
|
||||
|
|
Loading…
Reference in New Issue