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

debug:修复WebSocket数据不完整导致解析异常的问题 #322

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

Anekys
Copy link

@Anekys Anekys commented Sep 28, 2024

在排查这个问题的时候
#316
发现解析的WebSocket Frame大小不完整. 导致消息解析异常(类型和内容都不对)

解决方案:
新建一个成员变量buffer作为缓存.
先解析WebSocket的Header部分,从中提取出报文大小,待Frame完整以后再解析

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

Successfully merging this pull request may close these issues.

1 participant