As long as data of the in-flight response is not yet written
to the socket, we can reply an error response without corrupting
the client.
PR-URL: https://github.com/nodejs/node/pull/44818
Reviewed-By: Paolo Insogna <paolo@cowtech.it>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Ricky Zhou <0x19951125@gmail.com>
Let’s not have bad examples in our test suite and instead use the
proper way of converting stream data to UTF-8
(i.e. `stream.setEncoding('utf8')`) in all places.
PR-URL: https://github.com/nodejs/node/pull/43731
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Richard Lau <rlau@redhat.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Darshan Sen <raisinten@gmail.com>
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>