Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 340ca4d

Browse filesBrowse files
nicksia-vgwruyadorno
authored andcommitted
http: fix error message when specifying headerTimeout for createServer
This change fixes the message on the error received when calling http.createServer(...) with a header timeout greater than the request timeout is incorrect. The validation requires that the header timeout is lower than the request timeout, but the error message asks for the opposite. PR-URL: #44163 Reviewed-By: Paolo Insogna <paolo@cowtech.it> Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Tobias Nießen <tniessen@tnie.de> Reviewed-By: Erick Wendel <erick.workspace@gmail.com> Reviewed-By: Ricky Zhou <0x19951125@gmail.com>
1 parent 04007f2 commit 340ca4d
Copy full SHA for 340ca4d

File tree

Expand file treeCollapse file tree

1 file changed

+1
-1
lines changed
Open diff view settings
Filter options
Expand file treeCollapse file tree

1 file changed

+1
-1
lines changed
Open diff view settings
Collapse file

‎lib/_http_server.js‎

Copy file name to clipboardExpand all lines: lib/_http_server.js
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -425,7 +425,7 @@ function storeHTTPOptions(options) {
425425
}
426426

427427
if (this.requestTimeout > 0 && this.headersTimeout > 0 && this.headersTimeout >= this.requestTimeout) {
428-
throw new codes.ERR_OUT_OF_RANGE('headersTimeout', '>= requestTimeout', headersTimeout);
428+
throw new codes.ERR_OUT_OF_RANGE('headersTimeout', '< requestTimeout', headersTimeout);
429429
}
430430

431431
const keepAliveTimeout = options.keepAliveTimeout;

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.