| Index: net/dns/dns_hosts.cc
|
| diff --git a/net/dns/dns_hosts.cc b/net/dns/dns_hosts.cc
|
| index b4d213b80c451fa24935473b53a720732f8ede7e..697ea148e007f111c368b4b53d12d09daab1d780 100644
|
| --- a/net/dns/dns_hosts.cc
|
| +++ b/net/dns/dns_hosts.cc
|
| @@ -131,7 +131,6 @@ void ParseHostsWithCommaMode(const std::string& contents,
|
| DnsHosts* dns_hosts,
|
| ParseHostsCommaMode comma_mode) {
|
| CHECK(dns_hosts);
|
| - DnsHosts& hosts = *dns_hosts;
|
|
|
| StringPiece ip_text;
|
| IPAddressNumber ip;
|
| @@ -156,9 +155,9 @@ void ParseHostsWithCommaMode(const std::string& contents,
|
| } else {
|
| DnsHostsKey key(parser.token().as_string(), family);
|
| base::StringToLowerASCII(&key.first);
|
| - IPAddressNumber& mapped_ip = hosts[key];
|
| - if (mapped_ip.empty())
|
| - mapped_ip = ip;
|
| + IPAddressNumber* mapped_ip = &(*dns_hosts)[key];
|
| + if (mapped_ip->empty())
|
| + *mapped_ip = ip;
|
| // else ignore this entry (first hit counts)
|
| }
|
| }
|
|
|