stream: skip zero-byte broadcast writes#64772
Open
trivikr wants to merge 1 commit into
Open
Conversation
Collaborator
|
Review requested:
|
Zero-byte writes append entries to the broadcast buffer without
increasing bufferedBytes. This allows write('') and writev([]) to
bypass backpressure and grow the buffer without bound.
Treat zero-byte batches as successful no-ops, matching push streams,
and add coverage for the synchronous and asynchronous writer methods.
Signed-off-by: Kamat, Trivikram <16024985+trivikr@users.noreply.github.com>
Assisted-by: codex:gpt-5.6-sol
trivikr
force-pushed
the
stream-iter-zero-byte-broadcast
branch
from
July 27, 2026 02:13
8b411d6 to
f8d77be
Compare
avivkeller
approved these changes
Jul 27, 2026
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #64772 +/- ##
=======================================
Coverage 90.14% 90.14%
=======================================
Files 744 744
Lines 242518 242523 +5
Branches 45685 45693 +8
=======================================
+ Hits 218611 218624 +13
- Misses 15396 15401 +5
+ Partials 8511 8498 -13
🚀 New features to boost your workflow:
|
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.
Fixes: #64771
This change treats zero-byte batches as successful no-ops before they reach
the broadcast buffer, matching the existing push-stream behavior. It adds
coverage for the synchronous and asynchronous single-write and vector-write
methods.
Assisted-by: codex:gpt-5.6-sol