Avoid missing ref error in WriteStream.prototype.destroy().

pull/22966/head
Tobie Langel 2010-09-08 13:15:05 +02:00 committed by Ryan Dahl
parent 71651bf8b2
commit 75f922c863
1 changed files with 2 additions and 0 deletions

View File

@ -946,7 +946,9 @@ WriteStream.prototype.forceClose = function (cb) {
WriteStream.prototype.destroy = function (cb) {
var self = this;
this.writeable = false;
fs.close(self.fd, function(err) {
if (err) {
if (cb) {