Commit 624fa414 authored by Anna Henningsen's avatar Anna Henningsen Committed by Rich Trott
Browse files

http2: fix file close error condition at respondWithFd

Closing a FileHandle almost never fails, so it was hard to
notice before that `stream.emit(err)` would not emit an error
event due to the missing event name.

Destroying the stream with the error seems like the right thing
to do in that scenario.

PR-URL: https://github.com/nodejs/node/pull/29884


Reviewed-By: default avatarColin Ihrig <cjihrig@gmail.com>
Reviewed-By: default avatarRuben Bridgewater <ruben@bridgewater.de>
Reviewed-By: default avatarAnto Aravinth <anto.aravinth.cse@gmail.com>
Reviewed-By: default avatarDavid Carlier <devnexen@gmail.com>
Reviewed-By: default avatarYongsheng Zhang <zyszys98@gmail.com>
Reviewed-By: default avatarLuigi Pinca <luigipinca@gmail.com>
Reviewed-By: default avatarMinwoo Jung <minwoo@nodesource.com>
Reviewed-By: default avatarJames M Snell <jasnell@gmail.com>
Reviewed-By: default avatarGus Caplan <me@gus.host>
parent 5133e783
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment