Index: src/d8-debug.cc |
diff --git a/src/d8-debug.cc b/src/d8-debug.cc |
index 29055007ea9a9143e924067670c709e0a1b723cf..602ae166bea5acd9e7e04a2b5a4595aa920f6659 100644 |
--- a/src/d8-debug.cc |
+++ b/src/d8-debug.cc |
@@ -29,8 +29,9 @@ |
#include "d8.h" |
#include "d8-debug.h" |
-#include "platform.h" |
#include "debug-agent.h" |
+#include "platform.h" |
+#include "platform/socket.h" |
namespace v8 { |
@@ -171,21 +172,14 @@ void RunRemoteDebugger(Isolate* isolate, int port) { |
void RemoteDebugger::Run() { |
bool ok; |
- // Make sure that socket support is initialized. |
- ok = i::Socket::SetUp(); |
- if (!ok) { |
- printf("Unable to initialize socket support %d\n", i::Socket::LastError()); |
- return; |
- } |
- |
// Connect to the debugger agent. |
- conn_ = i::OS::CreateSocket(); |
+ conn_ = new i::Socket; |
static const int kPortStrSize = 6; |
char port_str[kPortStrSize]; |
i::OS::SNPrintF(i::Vector<char>(port_str, kPortStrSize), "%d", port_); |
ok = conn_->Connect("localhost", port_str); |
if (!ok) { |
- printf("Unable to connect to debug agent %d\n", i::Socket::LastError()); |
+ printf("Unable to connect to debug agent %d\n", i::Socket::GetLastError()); |
return; |
} |