Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MLST responses sometimes have blank lines which confuses GetEntry #321

Closed
ncw opened this issue Mar 28, 2023 · 0 comments
Closed

MLST responses sometimes have blank lines which confuses GetEntry #321

ncw opened this issue Mar 28, 2023 · 0 comments
Labels
defect The code does not work as intended

Comments

@ncw
Copy link
Contributor

ncw commented Mar 28, 2023

Describe the bug

Some FTP servers (in particular these two android servers, but there may be others

Return a blank line in their MLST responses.

To Reproduce

   MLST Download
    250-
    Size=53248;Modify=20230327134339.000;Type=dir; Download

    250 Requested file action okay, completed.

Expected behavior

This causes GetEntry to return this error

unsupported LIST line

FTP server

@ncw ncw added the defect The code does not work as intended label Mar 28, 2023
ncw added a commit to rclone/ftp that referenced this issue Mar 28, 2023
Some servers seem to send a blank line at the end of an MLST response.

    MLST Download
    250-
    Size=53248;Modify=20230327134339.000;Type=dir; Download

    250 Requested file action okay, completed.

Before this change this would cause the GetEntry method to return this
error.

    unsupported LIST line

This patch ignores blank lines in the MLST response.
ncw added a commit to rclone/ftp that referenced this issue Mar 28, 2023
Some servers seem to send a blank line at the end of an MLST response.

    MLST Download
    250-
    Size=53248;Modify=20230327134339.000;Type=dir; Download

    250 Requested file action okay, completed.

Before this change this would cause the GetEntry method to return this
error.

    unsupported LIST line

This patch ignores blank lines in the MLST response.

Signed-off-by: Nick Craig-Wood <[email protected]>
ncw added a commit to rclone/ftp that referenced this issue Mar 28, 2023
Some servers seem to send a blank line at the end of an MLST response.

    MLST Download
    250-
    Size=53248;Modify=20230327134339.000;Type=dir; Download

    250 Requested file action okay, completed.

Before this change this would cause the GetEntry method to return this
error.

    unsupported LIST line

This patch ignores blank lines in the MLST response.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
defect The code does not work as intended
Projects
None yet
Development

No branches or pull requests

1 participant