Skip to content

Commit

Permalink
Bug 2069: Improve compatibility with MVS systems
Browse files Browse the repository at this point in the history
https://winscp.net/tracker/2069
(cherry picked from commit 186c1aa)

Source commit: d4e8398afb469405f4eb0ee3e317c99b0126857b
  • Loading branch information
martinprikryl committed Apr 14, 2022
1 parent 77972b4 commit bbd9e26
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions source/core/FtpFileSystem.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1597,10 +1597,10 @@ void __fastcall TFTPFileSystem::CopyToLocal(TStrings * FilesToCopy,
UnicodeString TFTPFileSystem::RemoteExtractFilePath(const UnicodeString & Path)
{
UnicodeString Result;
// If the path ends with a slash, FZAPI CServerPath contructor does not identify the path as VMS.
// If the path ends with a slash, FZAPI CServerPath contructor does not identify the path as VMS nor MVS.
// It is probably ok to use UnixExtractFileDir for all paths passed to FZAPI,
// but for now, we limit the impact of the change to VMS.
if (FVMS)
// but for now, we limit the impact of the change to VMS/MVS.
if (FVMS || FMVS)
{
Result = UnixExtractFileDir(Path);
}
Expand Down Expand Up @@ -3504,7 +3504,7 @@ void __fastcall TFTPFileSystem::HandleReplyStatus(UnicodeString Response)
FTerminal->LogEvent(L"Server is known not to support LIST -a");
FListAll = asOff;
}
if ((FWorkFromCwd == asAuto) && FVMS)
if ((FWorkFromCwd == asAuto) && (FVMS || FMVS))
{
FTerminal->LogEvent(L"Server is known to require use of relative paths");
FWorkFromCwd = asOn;
Expand Down

0 comments on commit bbd9e26

Please sign in to comment.