[ADD] added chat to all method from docter, it works but there is sometimes an error in the doctor client app that the buffer in OnRead is full, so will try to fix that tomorrow
This commit is contained in:
@@ -190,6 +190,9 @@ namespace ClientApp.Utils
|
||||
expectedMessageLength = BitConverter.ToInt32(totalBuffer, 0);
|
||||
}
|
||||
|
||||
if (ar == null || (!ar.IsCompleted) || (!this.stream.CanRead) || !this.client.Connected)
|
||||
return;
|
||||
ar.AsyncWaitHandle.WaitOne();
|
||||
this.stream.BeginRead(this.buffer, 0, this.buffer.Length, new AsyncCallback(OnRead), null);
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user