| Index: runtime/bin/vmstats_impl.cc
|
| diff --git a/runtime/bin/vmstats_impl.cc b/runtime/bin/vmstats_impl.cc
|
| index d2e0af679d2f5933c7fc81d960170ce9b0e20c4c..0468a5144ba67ce50af785918de72f4343fb2a61 100644
|
| --- a/runtime/bin/vmstats_impl.cc
|
| +++ b/runtime/bin/vmstats_impl.cc
|
| @@ -55,15 +55,15 @@ void VmStats::StartServer(int port, const char* root_dir) {
|
| // TODO(tball): allow host to be specified.
|
| char* host = const_cast<char*>(DEFAULT_HOST);
|
| OSError* os_error;
|
| - const char* host_ip = Socket::LookupIPv4Address(host, &os_error);
|
| - if (host_ip == NULL) {
|
| + SocketAddresses* addresses = Socket::LookupAddress(host, -1, &os_error);
|
| + if (addresses == NULL) {
|
| Log::PrintErr("Failed IP lookup of VmStats host %s: %s\n",
|
| host, os_error->message());
|
| return;
|
| }
|
| -
|
| const intptr_t BACKLOG = 128; // Default value from HttpServer.dart
|
| - int64_t address = ServerSocket::CreateBindListen(host_ip, port, BACKLOG);
|
| + int64_t address = ServerSocket::CreateBindListen(
|
| + addresses->GetAt(0)->addr(), port, BACKLOG);
|
| if (address < 0) {
|
| Log::PrintErr("Failed binding VmStats socket: %s:%d\n", host, port);
|
| return;
|
|
|