Index: runtime/vm/dart_api_impl.cc |
diff --git a/runtime/vm/dart_api_impl.cc b/runtime/vm/dart_api_impl.cc |
index 8f131db016283467611944b983379745f0ccd7fd..f32f9594422257aa91e1b6401fc7d2e9cbb0392e 100644 |
--- a/runtime/vm/dart_api_impl.cc |
+++ b/runtime/vm/dart_api_impl.cc |
@@ -6512,7 +6512,7 @@ Dart_Handle Dart_LoadCompilationTrace(uint8_t* buffer, intptr_t buffer_length) { |
CHECK_NULL(buffer); |
CompilationTraceLoader loader(thread); |
const Object& error = |
- Object::Handle(loader.CompileTrace(reinterpret_cast<char*>(buffer))); |
+ Object::Handle(loader.CompileTrace(buffer, buffer_length)); |
if (error.IsError()) { |
return Api::NewHandle(T, Error::Cast(error).raw()); |
} |