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

stream: only increase awaitDrain once for each pipe destination #7292

Closed
wants to merge 1 commit into from
Closed

stream: only increase awaitDrain once for each pipe destination #7292

wants to merge 1 commit into from

Commits on Jun 14, 2016

  1. stream: ensure awaitDrain is increased once

    Guard against the call to write() inside pipe's ondata pushing more data
    back onto the Readable, thus causing ondata to be called again.
    
    This is fine but results in awaitDrain being increased more than once.
    The problem with that is when the destination does drain, only a single
    'drain' event is emitted, so awaitDrain in this case will never reach
    zero and we end up with a permanently paused stream.
    davedoesdev committed Jun 14, 2016
    Configuration menu
    Copy the full SHA
    02cbb90 View commit details
    Browse the repository at this point in the history