title: Read requests waiting on finished stream
body: <p>I'm using <a href="https://github.com/niegowski/node-pngjs" rel="noreferrer">pngjs</a> to read and write some PNGs. I'm getting this error periodically:</p>
  
  <pre><code>Error: There are some read requests waiting on finished stream
      at ChunkStream._end (/home/mbayazit/qatools/pdiff/node_modules/pngjs/lib/chunkstream.js:107:13)
      at ChunkStream.end (/home/mbayazit/qatools/pdiff/node_modules/pngjs/lib/chunkstream.js:94:14)
      at PNG.end (/home/mbayazit/qatools/pdiff/node_modules/pngjs/lib/png.js:105:18)
      at ReadStream.onend (_stream_readable.js:483:10)
      at ReadStream.g (events.js:175:14)
      at ReadStream.EventEmitter.emit (events.js:117:20)
      at _stream_readable.js:910:16
      at process._tickCallback (node.js:415:13)
  </code></pre>
  
  <p>But it doesn't give me a line-number inside my program.</p>
  
  <p>I only deal with streams in a few places though, they are:</p>
  
  <pre><code>fs.createReadStream(oldScreen).pipe(new PNG).on('parsed', function() {
      promises[0].resolve(this);
  });
  
  fs.createReadStream(newScreen).pipe(new PNG).on('parsed', function() {
      promises[1].resolve(this);
  });
  </code></pre>
  
  <p>And</p>
  
  <pre><code>result.png.pack().pipe(fs.createWriteStream(diffName));
  </code></pre>
  
  <p>The three filenames are never the same, so they shouldn't be reading/writing to the same place. I suppose it's possible that a stream did not get closed properly from a previous failed run though. Is there a way I can force all the streams to close nicely?</p>