Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

websoket server System.IndexOutOfRangeException #265

Open
liu3104009029 opened this issue Aug 9, 2023 · 1 comment
Open

websoket server System.IndexOutOfRangeException #265

liu3104009029 opened this issue Aug 9, 2023 · 1 comment

Comments

@liu3104009029
Copy link

liu3104009029 commented Aug 9, 2023

websoket server
at storeWSCloseStatus, when u close the networking,it will show exception: Index was outside the bounds of the array
the source code from websocket.cs line 306 : WsSendBuffer.Data[offset + i] = (byte)(buffer[i] ^ WsSendMask[i % 4]);
i think the reason is, at line 257: long size = storeWSCloseStatus ? (buffer.Length + 2) : buffer.Length;
then the buffer.Length < size

@chronoxor
Copy link
Owner

Fixed in 8.0.1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants