NativeWebSocket
NativeWebSocket copied to clipboard
Perform array copies outside of `lock`s in Receive
Call ms.ToArray() outside of the lock (IncomingMessageLock) sections in Receive(). This prevents the Unity main thread blocking on IncomingMessageLock if ms.ToArray() is copying a large number of bytes.