Skip to content

Commit

Permalink
net: remove hot path comment from connect
Browse files Browse the repository at this point in the history
This comment was added with an assumption that we could determine the
IP address that localhost should resolve to without performing a
lookup. This was a false assumption and should be removed.

PR-URL: nodejs#4648
Reviewed-By: Brian White <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
  • Loading branch information
evanlucas authored and Michael Scovetta committed Apr 2, 2016
1 parent 960d6fb commit 5725f89
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion lib/net.js
Original file line number Diff line number Diff line change
Expand Up @@ -933,7 +933,6 @@ function lookupAndConnect(self, options) {
port |= 0;

// If host is an IP, skip performing a lookup
// TODO(evanlucas) should we hot path this for localhost?
var addressType = exports.isIP(host);
if (addressType) {
process.nextTick(function() {
Expand Down

0 comments on commit 5725f89

Please sign in to comment.