Index: src/d8.cc |
diff --git a/src/d8.cc b/src/d8.cc |
index bce9103f6499fbbafb869c2085d5a40e69e523df..31ae7923af449c6087bd859d49b6bfbc8628bd56 100644 |
--- a/src/d8.cc |
+++ b/src/d8.cc |
@@ -1867,7 +1867,7 @@ class InspectorClient : public v8_inspector::V8InspectorClient { |
v8_inspector::V8InspectorSession* session = |
InspectorClient::GetSession(context); |
int length = message->Length(); |
- std::unique_ptr<uint16_t> buffer(new uint16_t[length]); |
+ std::unique_ptr<uint16_t[]> buffer(new uint16_t[length]); |
message->Write(buffer.get(), 0, length); |
v8_inspector::StringView message_view(buffer.get(), length); |
session->dispatchProtocolMessage(message_view); |