Skip to content

Commit

Permalink
Fixes https host header default port handling.
Browse files Browse the repository at this point in the history
  • Loading branch information
mikeal authored and isaacs committed Aug 8, 2011
1 parent ef35f4d commit 24a1f6e
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions lib/http2.js
Original file line number Diff line number Diff line change
Expand Up @@ -1259,6 +1259,7 @@ exports.request = function(options, cb) {
if (options.agent === undefined) {
options.agent = globalAgent;
}
options.defaultPort = options.defaultPort || 80;
return new ClientRequest(options, cb);
};

Expand Down
1 change: 1 addition & 0 deletions lib/https2.js
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,7 @@ exports.request = function(options, cb) {
if (options.agent === undefined) {
options.agent = globalAgent;
}
options.defaultPort = options.defaultPort || 443;
return http.request(options, cb);
};

Expand Down

0 comments on commit 24a1f6e

Please sign in to comment.