diff --git a/lib/plugins/bodyReader.js b/lib/plugins/bodyReader.js index a71cfb0be..82c9d1016 100644 --- a/lib/plugins/bodyReader.js +++ b/lib/plugins/bodyReader.js @@ -186,7 +186,7 @@ function bodyReader(options) { // add 'close and 'aborted' event handlers so that requests (and their // corresponding memory) don't leak if client stops sending data half // way through a POST request - req.once('close', next); + req.socket.once('close', next); req.once('aborted', next); req.resume(); }