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

fix websocket transport #238

Merged
merged 2 commits into from
Apr 1, 2024
Merged

fix websocket transport #238

merged 2 commits into from
Apr 1, 2024

Conversation

turuslan
Copy link
Contributor

  • fix wrong observed address caused by missing "/ws" "/wss" in TcpConnection::remoteMultiaddr().
    • pass layers to TcpConnection constructor.
  • fix yamux use-after-free ub.
    • (Refactor unsafe code #226) std::function or boost asio handler didn't move Bytes, so BytesIn referenced first Bytes which were destroyed after copying.
    • callback captures shared_ptr<Bytes> YamuxedConnection::writing_buf_ to keep BytesIn reference valid.

@turuslan turuslan requested a review from xDimon April 1, 2024 06:43
@turuslan turuslan merged commit 3cdf68a into master Apr 1, 2024
1 of 5 checks passed
@turuslan turuslan deleted the fix/ws-observed branch April 1, 2024 06:51
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.

3 participants