Index: src/log.cc |
diff --git a/src/log.cc b/src/log.cc |
index e1ebc87c65f6c2526373bda52edb5b3004c20304..891b0e2b8296b428daacbc91654bf780d2e9dd75 100644 |
--- a/src/log.cc |
+++ b/src/log.cc |
@@ -1313,9 +1313,8 @@ void Logger::LogCodeObjects() { |
void Logger::LogCompiledFunctions() { |
HandleScope scope; |
const int compiled_funcs_count = EnumerateCompiledFunctions(NULL); |
- Handle<SharedFunctionInfo>* sfis = |
- NewArray< Handle<SharedFunctionInfo> >(compiled_funcs_count); |
- EnumerateCompiledFunctions(sfis); |
+ ScopedVector< Handle<SharedFunctionInfo> > sfis(compiled_funcs_count); |
+ EnumerateCompiledFunctions(sfis.start()); |
// During iteration, there can be heap allocation due to |
// GetScriptLineNumber call. |
@@ -1360,8 +1359,6 @@ void Logger::LogCompiledFunctions() { |
Logger::LAZY_COMPILE_TAG, shared->code(), *func_name)); |
} |
} |
- |
- DeleteArray(sfis); |
} |