Skip to content
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
stream: inline unbuffered _write
  • Loading branch information
ronag committed Apr 16, 2020
commit 4144d55f5ad2f98570b4b64ec4754b09cd7020fb
7 changes: 6 additions & 1 deletion lib/_stream_writable.js
Original file line number Diff line number Diff line change
Expand Up @@ -364,7 +364,12 @@ function writeOrBuffer(stream, state, chunk, encoding, cb) {
}
state.bufferedRequestCount += 1;
} else {
doWrite(stream, state, false, len, chunk, encoding, cb);
state.writelen = len;
state.writecb = cb;
state.writing = true;
state.sync = true;
stream._write(chunk, encoding, state.onwrite);
state.sync = false;
}

// Return false if errored or destroyed in order to break
Expand Down