Allow for loopback addresses in a hosts file
Project: http://git-wip-us.apache.org/repos/asf/trafficserver/repo Commit: http://git-wip-us.apache.org/repos/asf/trafficserver/commit/0c030e25 Tree: http://git-wip-us.apache.org/repos/asf/trafficserver/tree/0c030e25 Diff: http://git-wip-us.apache.org/repos/asf/trafficserver/diff/0c030e25 Branch: refs/heads/master Commit: 0c030e25290dc10a8193b4e605ce884caed97ae6 Parents: 078a9a8 Author: Thomas Jackson <[email protected]> Authored: Mon Jul 6 19:21:53 2015 -0700 Committer: Thomas Jackson <[email protected]> Committed: Tue Jul 7 19:19:31 2015 -0700 ---------------------------------------------------------------------- iocore/hostdb/HostDB.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/trafficserver/blob/0c030e25/iocore/hostdb/HostDB.cc ---------------------------------------------------------------------- diff --git a/iocore/hostdb/HostDB.cc b/iocore/hostdb/HostDB.cc index 72d86f5..cd029db 100644 --- a/iocore/hostdb/HostDB.cc +++ b/iocore/hostdb/HostDB.cc @@ -2615,7 +2615,7 @@ ParseHostLine(char *l) // Elements should be the address then a list of host names. // Don't use RecHttpLoadIp because the address *must* be literal. IpAddr ip; - if (n_elts > 1 && 0 == ip.load(elts[0]) && !ip.isLoopback()) { + if (n_elts > 1 && 0 == ip.load(elts[0])) { for (int i = 1; i < n_elts; ++i) { ts::ConstBuffer name(elts[i], strlen(elts[i])); // If we don't have an entry already (host files only support single IPs for a given name)
