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

Dispose when using EnableThreadSafeDataConnections #275

srz2 opened this issue Feb 19, 2018 · 1 comment


None yet
2 participants
Copy link

commented Feb 19, 2018

FTP OS: Embedded

FTP Server: Vsftpd

Computer OS: Windows 10

Is there effort to debug EnableThreadSafeDataConnections? I know you've said this is a legacy item which is default to off but I've been using it and it seems to occasionally break. When i async download files every few files i attempt (6-18) this fails and the connection never comes back. I hit the dispose method when this occurs

Logs :

# Dispose()
Status:   Disposing FtpClient object...
Status:   There is stale data on the socket, maybe our connection timed out or you did not call GetReply(). Re-connecting...
Status:   The stale data was: 226 File send OK.
Status:   Disposing FtpSocketStream...
Status:   Not sending QUIT because the connection has already been closed.
Status:   Disposing FtpSocketStream...
Status:   Disposing FtpSocketStream...```

This comment has been minimized.

Copy link

commented Feb 22, 2018

Its built by the original author. No idea what he was trying to do with it. As far as I understand, it opens a new FtpClient instance per transfer which creates a lot of unnecessary connections. If you need multi-threaded operation consider using a BackgroundWorker or Thread and creating an FtpClient on that thread.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.