Permalink
Browse files

Added a test for missing response.socket property on second piped res…

…ponse object.(thanks to koichik)
  • Loading branch information...
1 parent d894de7 commit 4ed5f1e6c051b267213c8e6088e2a5287119d1b3 @neocoder committed Apr 7, 2011
Showing with 2 additions and 1 deletion.
  1. +1 −1 lib/http.js
  2. +1 −0 test/simple/test-gets-auto-fd.js
View
2 lib/http.js
@@ -386,7 +386,7 @@ OutgoingMessage.prototype._writeRaw = function(data, encoding) {
this.connection.write(c, e);
}
-
+ // buffer data if socket is not yet writable
if ( !this.connection.writable ) {
this._buffer(data, encoding);
return false;
View
1 test/simple/test-gets-auto-fd.js
@@ -7,6 +7,7 @@ var server = net.createServer();
//test unix sockets
var fds = process.binding('net').socketpair();
var unixsocket = new net.Socket(fds[0]);
+
assert.ok(unixsocket.type == 'unix', 'Should be UNIX');
//test that stdin is default file

0 comments on commit 4ed5f1e

Please sign in to comment.