FubarDevelopment / FtpServer

Portable FTP server written in .NET
http://fubardevelopment.github.io/FtpServer/
MIT License
472 stars 161 forks source link

Error when stopping the server #126

Open mcschuetz opened 2 years ago

mcschuetz commented 2 years ago

I get the following error:

Failed to stop the client connection: The CancellationTokenSource has been disposed.
System.ObjectDisposedException: The CancellationTokenSource has been disposed.
   at System.Threading.CancellationTokenSource.ThrowObjectDisposedException()
   at FubarDev.FtpServer.FtpConnection.ConnectionClosingNetworkStreamReader.OnCloseAsync(Exception exception, CancellationToken cancellationToken)
   at FubarDev.FtpServer.Networking.PausableFtpService.StopAsync(CancellationToken cancellationToken)
   at FubarDev.FtpServer.FtpConnection.StopAsync()

The crazy thing is that this error occurs in the middle of the night with no access to the server. I can not understand why this occurs.

The target state should actually be that it always runs without pause/stop.

Thanks for help!

fubar-coder commented 2 years ago

Hmm, the "middle of the night". Sounds like an internet disconnect from the ISP while a client still has an active connection. Connection loss is something that I need to test.