| Index: chrome/browser/local_discovery/privet_http_asynchronous_factory_impl.cc
|
| diff --git a/chrome/browser/local_discovery/privet_http_asynchronous_factory_impl.cc b/chrome/browser/local_discovery/privet_http_asynchronous_factory_impl.cc
|
| index b01795490fd24402ec0a25e9bb82ad08d8234a43..8e2b2c6cc529b91ab62ebb064aa6dfbf21223f10 100644
|
| --- a/chrome/browser/local_discovery/privet_http_asynchronous_factory_impl.cc
|
| +++ b/chrome/browser/local_discovery/privet_http_asynchronous_factory_impl.cc
|
| @@ -14,21 +14,6 @@
|
|
|
| namespace local_discovery {
|
|
|
| -namespace {
|
| -
|
| -std::string IPAddressToHostString(const net::IPAddressNumber& address) {
|
| - std::string address_str = net::IPAddressToString(address);
|
| -
|
| - // IPv6 addresses need to be surrounded by brackets.
|
| - if (address.size() == net::kIPv6AddressSize) {
|
| - address_str = base::StringPrintf("[%s]", address_str.c_str());
|
| - }
|
| -
|
| - return address_str;
|
| -}
|
| -
|
| -} // namespace
|
| -
|
| PrivetHTTPAsynchronousFactoryImpl::PrivetHTTPAsynchronousFactoryImpl(
|
| net::URLRequestContextGetter* request_context)
|
| : request_context_(request_context) {
|
| @@ -119,7 +104,7 @@ void PrivetHTTPAsynchronousFactoryImpl::ResolutionImpl::DomainResolveComplete(
|
| DCHECK(!address.empty());
|
|
|
| net::HostPortPair new_address =
|
| - net::HostPortPair(IPAddressToHostString(address), port);
|
| + net::HostPortPair::FromIPEndPoint(net::IPEndPoint(address, port));
|
| callback.Run(scoped_ptr<PrivetHTTPClient>(
|
| new PrivetHTTPClientImpl(name_, new_address, request_context_.get())));
|
| }
|
|
|