-
-
Notifications
You must be signed in to change notification settings - Fork 971
Open
Description
System Information:
- Library version:
<PackageReference Include="SSH.NET" Version="2024.2.0" /> - .NET 9.0
- Running on Windows 10 x64
Problem:
When I invoke the Disconnect method, a SocketException is thrown.
The problem is that I have to call this code in multiple iterations and I need to re-create the connection every time. The exception is a perf hit.
Repro code:
The repro code is very simple. I tried both Connect and ConnectAsync with no differences.
As soon as I try to either Disconnect or Dispose (which calls Disconnect), the Exception is thrown.
_client = new SshClient(connectionInfo);
_client.Connect(); // //await _client.ConnectAsync(default);
_client.Disconnect(); // Exception explodes here
_client.Dispose();
System.Net.Sockets.SocketException: 'A blocking operation was interrupted by a call to WSACancelBlockingCall.'
dimaaan and wa926talent
Metadata
Metadata
Assignees
Labels
No labels

