[Modify] Polish it

This commit is contained in:
sta 2019-08-25 22:05:12 +09:00
parent 7ae2132dc5
commit 14f579afc8

View File

@ -597,14 +597,15 @@ Extended Payload Length: {7}
Action<Exception> error
)
{
var len = frame.IsMasked ? 4 : 0;
if (len == 0) {
if (!frame.IsMasked) {
frame._maskingKey = WebSocket.EmptyBytes;
completed (frame);
return;
}
var len = 4;
stream.ReadBytesAsync (
len,
bytes => {