Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(648)

Unified Diff: src/isolate.cc

Issue 7660016: Fix memory leaks in ~Zone and ~Isolate (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: addressed comments Created 9 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | src/serialize.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/isolate.cc
diff --git a/src/isolate.cc b/src/isolate.cc
index 9ca61177ba7b41914987dbf0aaba503b50ab2773..eae812bcd94bdc35c4d48a497a17375fc332fd5f 100644
--- a/src/isolate.cc
+++ b/src/isolate.cc
@@ -1533,6 +1533,9 @@ void Isolate::SetIsolateThreadLocals(Isolate* isolate,
Isolate::~Isolate() {
TRACE_ISOLATE(destructor);
+ // Has to be called while counters_ are still alive.
+ zone_.DeleteKeptSegment();
+
delete unicode_cache_;
unicode_cache_ = NULL;
@@ -1591,6 +1594,9 @@ Isolate::~Isolate() {
delete global_handles_;
global_handles_ = NULL;
+ delete external_reference_table_;
+ external_reference_table_ = NULL;
+
#ifdef ENABLE_DEBUGGER_SUPPORT
delete debugger_;
debugger_ = NULL;
« no previous file with comments | « no previous file | src/serialize.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698