Repository navigation
Conversation
…nd, as max_message_size() basic_peer_connection::max_message_size() is the smaller of options::max_message_size and the peer's announced limit, the limit each channel's send checks: natively libdatachannel's rtcGetRemoteMaxMessageSize once a remote description is applied, in the browser the SCTP transport's maxMessageSize (Infinity for none) once the connection has one; nothing before. native_test checks it before negotiation and against real sends between peers of different limits; browser_backend_test against the fake transport's sctp, including a refused send at the same limit.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
A peer connection reports the largest message its data channels send, as
max_message_size(): natively libdatachannel'srtcMaxMessageSizeonce a remote description is applied, in a page the browser'spc.sctp.maxMessageSize, both withinoptions::max_message_size. The library already read both values to gate its sends; this makes the one value public, so that webcpp::trystero's port to Trystero 0.27.0 decides wide bulk chunks from the transport itself, as Trystero 0.27.0 does, instead of rebuilding it from the SDP (ruling P2-R29 of that port).Tested natively and with Emscripten (webrtc's own tests). Merges together with webcpporg/trystero#10 and webcpporg/webcpp#51, which hold until webcpp::crypto's API changes land (draft).