diff options
author | isaacs <i@izs.me> | 2012-05-03 10:39:16 -0700 |
---|---|---|
committer | isaacs <i@izs.me> | 2012-05-04 14:31:08 -0700 |
commit | 0abe42a0f4be80bd659411656503e7ac2c243813 (patch) | |
tree | 6e7957346c8c8bf816c6bb1c48b9a0ef65abac1a /lib | |
parent | e63c7821d5fc4e2f92c0606ab16b7846893ac3d1 (diff) | |
download | android-node-v8-0abe42a0f4be80bd659411656503e7ac2c243813.tar.gz android-node-v8-0abe42a0f4be80bd659411656503e7ac2c243813.tar.bz2 android-node-v8-0abe42a0f4be80bd659411656503e7ac2c243813.zip |
http: .once() usage in setTimeout
Diffstat (limited to 'lib')
-rw-r--r-- | lib/http.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/http.js b/lib/http.js index 30285eec63..2468e2c84c 100644 --- a/lib/http.js +++ b/lib/http.js @@ -1494,13 +1494,13 @@ ClientRequest.prototype.setTimeout = function(msecs, callback) { } if (this.socket) { - this.socket.on('connect', function() { + this.socket.once('connect', function() { this.setTimeout(msecs, emitTimeout); }); return; } - this.on('socket', function(sock) { + this.once('socket', function(sock) { this.setTimeout(msecs, emitTimeout); }); }; |