Skip to content

Commit

Permalink
Bug 2076: z/OS PDS members without ISPF statistics are omitted in dir…
Browse files Browse the repository at this point in the history
…ectory listing

https://winscp.net/tracker/2076
(cherry picked from commit 160289d)

Source commit: 51fb0cd95b29b712d388ef7feca554864f34975d
  • Loading branch information
martinprikryl committed May 17, 2022
1 parent 48b1e3a commit 942eccb
Showing 1 changed file with 10 additions and 5 deletions.
15 changes: 10 additions & 5 deletions source/filezilla/FtpListResult.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -303,12 +303,17 @@ BOOL CFtpListResult::parseLine(const char *lineToParse, const int linelen, t_dir

// name-only entries
// (multiline VMS entries have only a name on the first line, so for VMS we have to skip this)
if (FLAGCLEAR(m_server.nServerType, FZ_SERVERTYPE_SUB_FTP_VMS) &&
(strchr(lineToParse, ' ') == NULL))
if (FLAGCLEAR(m_server.nServerType, FZ_SERVERTYPE_SUB_FTP_VMS))
{
direntry = t_directory::t_direntry();
copyStr(direntry.name, 0, lineToParse, strlen(lineToParse));
return TRUE;
RawByteString Buf(lineToParse);
// z/OS PDS members without ISPF statistics (name only) still have loads of spaces after them.
Buf = Buf.TrimRight();
if (Buf.Pos(' ') == 0)
{
direntry = t_directory::t_direntry();
direntry.name = Buf.c_str();
return TRUE;
}
}

return FALSE;
Expand Down

0 comments on commit 942eccb

Please sign in to comment.