The data contained in this repository can be downloaded to your computer using one of several clients.
Please see the documentation of your version control software client for more information.

Please select the desired protocol below to get the URL.

This URL has Read-Only access.

Statistics
| Branch: | Revision:

main_repo / test / simple / test-fs-stream-double-close.js @ 6f043940

History | View | Annotate | Download (2.01 KB)

# Date Author Comment
47d6a946 05/02/2012 07:01 PM Ben Noordhuis

fs: fix ReadStream / WriteStream double close bug

  • Calling fs.ReadStream.destroy() or fs.WriteStream.destroy() twice would close
    the file descriptor twice. That's bad because the file descriptor may have
    been repurposed in the mean time.
  • A bad value check in fs.ReadStream.prototype.destroy() would prevent a stream...