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: #4648
Reviewed-By: Brian White <mscdex@mscdex.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
  • Loading branch information
evanlucas committed Jan 12, 2016
1 parent 0f3d75e commit 3a7f106
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 3a7f106

Please sign in to comment.