1
0
mirror of https://github.com/winscp/winscp.git synced 2026-10-24 02:28:55 +03:00

Bug 1546: On VMS servers, do not use absolute paths with DELE command (2nd)

https://winscp.net/tracker/1546

Source commit: fe0d54d899d3db357f3899d1b0a3d39451843638
This commit is contained in:
Martin Prikryl
2017-06-28 07:34:00 +00:00
parent 0a848d1b66
commit cae4c0255c

View File

@@ -866,17 +866,18 @@ UnicodeString __fastcall TFTPFileSystem::ActualCurrentDirectory()
//---------------------------------------------------------------------------
void __fastcall TFTPFileSystem::EnsureLocation(const UnicodeString & Directory, bool Log)
{
if (!UnixSamePath(ActualCurrentDirectory(), Directory))
UnicodeString ADirectory = UnixExcludeTrailingBackslash(Directory);
if (!UnixSamePath(ActualCurrentDirectory(), ADirectory))
{
if (Log)
{
FTerminal->LogEvent(FORMAT(L"Synchronizing current directory \"%s\".",
(Directory)));
(ADirectory)));
}
DoChangeDirectory(Directory);
DoChangeDirectory(ADirectory);
// make sure FZAPI is aware that we changed current working directory
FFileZillaIntf->SetCurrentPath(Directory.c_str());
FFileZillaIntf->SetCurrentPath(ADirectory.c_str());
}
}
//---------------------------------------------------------------------------