chronoxor / NetCoreServer

Ultra fast and low latency asynchronous socket server & client C# .NET Core library with support TCP, SSL, UDP, HTTP, HTTPS, WebSocket protocols and 10K connections problem solution
https://chronoxor.github.io/NetCoreServer
MIT License
2.63k stars 550 forks source link

WebSocket: unhandled exception #258

Closed ilsnk closed 7 months ago

ilsnk commented 1 year ago

I don't know the steps to reproduce, but someone, tell me where to wear a fix?

Unhandled exception. System.ArgumentOutOfRangeException: Specified argument was out of the range of valid values. (Parameter 'length')
   at System.Runtime.CompilerServices.RuntimeHelpers.GetSubArray[T](T[] array, Range range)
   at NetCoreServer.WebSocket.PrepareReceiveFrame(Byte[] buffer, Int64 offset, Int64 size)
   at NetCoreServer.TcpSession.ProcessReceive(SocketAsyncEventArgs e)
   at NetCoreServer.TcpSession.OnAsyncCompleted(Object sender, SocketAsyncEventArgs e)
   at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state)
--- End of stack trace from previous location ---
   at System.Net.Sockets.SocketAsyncEngine.System.Threading.IThreadPoolWorkItem.Execute()
   at System.Threading.ThreadPoolWorkQueue.Dispatch()
   at System.Threading.PortableThreadPool.WorkerThread.WorkerThreadStart()
ilsnk commented 7 months ago

duplicate issue, acutal thread: https://github.com/chronoxor/NetCoreServer/issues/279