0
0
mirror of https://github.com/nodejs/node.git synced 2024-11-30 07:27:22 +01:00

Fix ability to disable TCP timeouts with setTimeout(0)

This commit is contained in:
Ryan Dahl 2010-06-03 11:01:47 -07:00
parent 987cbe35c6
commit 62d9bff06b

View File

@ -937,6 +937,8 @@ Stream.prototype.setTimeout = function (msecs) {
if (msecs > 0) {
timeout.enroll(this, msecs);
if (this.fd) { timeout.active(this); }
} else if (msecs === 0) {
timeout.unenroll(this);
}
};