egametang 我打印了日志,是会走到WChannel的Dispose的,整个调用顺序为:
1.receiveResult = await this.webSocket.ReceiveAsync( new Memory<byte>(cache, receiveCount, this.cache.Length - receiveCount), cancellationTokenSource.Token);这边抛出异常
2.StartRecv()补货异常走this.OnError(ErrorCore.ERR_WebsocketRecvError);
3.OnError中会this.Service.Remove(channelId);
4.被Service移除后,调用WChannel的Dispose, dispose中有this.webSocket.Dispose();
主要是此时的webSocket是aborted状态,可能正常的close关不掉