| Index: net/base/host_port_pair.cc
|
| diff --git a/net/base/host_port_pair.cc b/net/base/host_port_pair.cc
|
| index 6675692123a58a26091fdd8b1a290c139185fc7c..18cf9f5e7b2de6d14df0a957d0583b9dafac1947 100644
|
| --- a/net/base/host_port_pair.cc
|
| +++ b/net/base/host_port_pair.cc
|
| @@ -10,6 +10,7 @@
|
| #include "base/strings/string_util.h"
|
| #include "base/strings/stringprintf.h"
|
| #include "net/base/ip_endpoint.h"
|
| +#include "net/base/net_util.h"
|
| #include "url/gurl.h"
|
|
|
| namespace net {
|
| @@ -36,7 +37,8 @@ HostPortPair HostPortPair::FromString(const std::string& str) {
|
| int port;
|
| if (!base::StringToInt(key_port[1], &port))
|
| return HostPortPair();
|
| - DCHECK_LT(port, 1 << 16);
|
| + if (!IsPortValid(port))
|
| + return HostPortPair();
|
| HostPortPair host_port_pair;
|
| host_port_pair.set_host(key_port[0]);
|
| host_port_pair.set_port(port);
|
|
|