| Index: net/dns/dns_hosts.cc
|
| diff --git a/net/dns/dns_hosts.cc b/net/dns/dns_hosts.cc
|
| index 098c6172511ce5f095105bb9c9017db112b3476c..568a9ce5558c0f12d05242371314c7789ff5157a 100644
|
| --- a/net/dns/dns_hosts.cc
|
| +++ b/net/dns/dns_hosts.cc
|
| @@ -9,6 +9,7 @@
|
| #include "base/macros.h"
|
| #include "base/metrics/histogram_macros.h"
|
| #include "base/strings/string_util.h"
|
| +#include "net/dns/dns_util.h"
|
|
|
| using base::StringPiece;
|
|
|
| @@ -155,6 +156,8 @@ void ParseHostsWithCommaMode(const std::string& contents,
|
| }
|
| } else {
|
| DnsHostsKey key(parser.token().as_string(), family);
|
| + if (!IsValidDNSDomain(key.first))
|
| + continue;
|
| key.first = base::ToLowerASCII(key.first);
|
| IPAddress* mapped_ip = &(*dns_hosts)[key];
|
| if (mapped_ip->empty())
|
|
|