Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Attempt to call `destroy()` on `Gunzip` object #71

Closed
ggoodman opened this issue Feb 3, 2015 · 0 comments
Closed

Attempt to call `destroy()` on `Gunzip` object #71

ggoodman opened this issue Feb 3, 2015 · 0 comments
Assignees
Labels
bug
Milestone

Comments

@ggoodman
Copy link
Contributor

@ggoodman ggoodman commented Feb 3, 2015

To reproduce:

  1. Hapi server with parse: true or parse: gzip in a route handler.
  2. Issue a request with payload of application/json whose inflated size exceeds the server's maxBytes setting.
  3. Compress the request with Content-Encoding: gzip to a size that no longer exceeds the server's maxBytes setting.

Trace:

Debug: internal, implementation, error 
    TypeError: Object #<Gunzip> has no method 'destroy'
    at exports.read.onReaderError (/path_to_app/node_modules/hapi/node_modules/wreck/lib/index.js:263:13)
    at g (events.js:180:16)
    at emit (events.js:117:20)
    at internals.Recorder._write (/path_to_app/node_modules/hapi/node_modules/wreck/lib/recorder.js:31:21)
    at doWrite (_stream_writable.js:226:10)
    at writeOrBuffer (_stream_writable.js:216:5)
    at Writable.write (_stream_writable.js:183:11)
    at write (_stream_readable.js:602:24)
    at flow (_stream_readable.js:611:7)
    at Gunzip.pipeOnReadable (_stream_readable.js:643:5)
    at Gunzip.emit (events.js:92:17)
    at emitReadable_ (_stream_readable.js:427:10)
    at emitReadable (_stream_readable.js:423:5)
    at readableAddChunk (_stream_readable.js:166:9)
    at Gunzip.Readable.push (_stream_readable.js:128:10)
    at Gunzip.Transform.push (_stream_transform.js:140:32)
@hueniverse hueniverse added the bug label Feb 4, 2015
@hueniverse hueniverse self-assigned this Jul 1, 2015
@geek geek closed this in 2279fd0 Jul 1, 2015
geek added a commit that referenced this issue Jul 1, 2015
Skip res.destroy() when not present. Closes #71
@hueniverse hueniverse added this to the 5.6.1 milestone Jul 1, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.