src: unconsume stream fix in internal http impl
When emitting a 'connection' event on a httpServer, the function connectionListener is called. Then, a new parser is created, and 'consume' method is called on the socket's externalStream. However, if this stream was already consumed and unconsumed, the process crashes with a cpp assert from the 'Consume' method in stream_base.h. This commit makes sure that no SIGABRT will be raised and the process will stay alive (after emitting the socket). PR-URL: https://github.com/nodejs/node/pull/11015 Reviewed-By:Fedor Indutny <fedor.indutny@gmail.com> Reviewed-By:
James M Snell <jasnell@gmail.com>
parent
10b687b5
Please register or sign in to comment