You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[browser][websocket] Canceling token source before connect should throw OperationCanceledException #44720
The WebSocketClient should throw an OperationCanceledException instead of trying to connect and then cancelling.
using (var clientSocket = new ClientWebSocket())
{
var cts = new CancellationTokenSource();
cts.Cancel();
Task t = clientSocket.ConnectAsync(new Uri("ws://" + Guid.NewGuid().ToString("N")), cts.Token);
}
Activity