| Index: net/base/ip_address_number.cc
|
| diff --git a/net/base/ip_address_number.cc b/net/base/ip_address_number.cc
|
| index 1e44b7d3b1ebcc74873fa762eb0ced94411c188d..07fb792d8b31b43cc972fb565a027761ba9d7f3d 100644
|
| --- a/net/base/ip_address_number.cc
|
| +++ b/net/base/ip_address_number.cc
|
| @@ -103,7 +103,7 @@ std::string IPAddressToString(const uint8_t* address, size_t address_len) {
|
| } else if (address_len == kIPv6AddressSize) {
|
| url::AppendIPv6Address(address, &output);
|
| } else {
|
| - CHECK(false) << "Invalid IP address with length: " << address_len;
|
| + return std::string();
|
| }
|
|
|
| output.Complete();
|
| @@ -114,6 +114,8 @@ std::string IPAddressToStringWithPort(const uint8_t* address,
|
| size_t address_len,
|
| uint16_t port) {
|
| std::string address_str = IPAddressToString(address, address_len);
|
| + if (address_str.empty())
|
| + return address_str;
|
|
|
| if (address_len == kIPv6AddressSize) {
|
| // Need to bracket IPv6 addresses since they contain colons.
|
|
|