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

quic: remove noop code #33914

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 1 addition & 21 deletions lib/internal/quic/core.js
Original file line number Diff line number Diff line change
Expand Up @@ -2585,6 +2585,7 @@ class QuicStream extends Duplex {
highWaterMark,
defaultEncoding,
} = options;

super({
highWaterMark,
defaultEncoding,
Expand All @@ -2601,27 +2602,6 @@ class QuicStream extends Duplex {
this._readableState.readingMore = true;
this.on('pause', streamOnPause);

// See src/node_quic_stream.h for an explanation
// of the initial states for unidirectional streams.
if (this.unidirectional) {
if (session instanceof QuicServerSession) {
if (this.serverInitiated) {
// Close the readable side
this.push(null);
this.read();
} else {
// Close the writable side
this.end();
}
} else if (this.serverInitiated) {
// Close the writable side
this.end();
} else {
this.push(null);
this.read();
}
}

// The QuicStream writes are corked until kSetHandle
// is set, ensuring that writes are buffered in JavaScript
// until we have somewhere to send them.
Expand Down