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

Unified Diff: src/debug.cc

Issue 13799003: Change Context::New not create persistent handles. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Adapted cctest initialization to new API. Created 7 years, 8 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 | « src/bootstrapper.cc ('k') | test/cctest/cctest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/debug.cc
diff --git a/src/debug.cc b/src/debug.cc
index 91af9ccc1bab32cb351006da1d51de108c6a006e..b862c51b0f26a5308f5bbe1266b0b21f6cf31c33 100644
--- a/src/debug.cc
+++ b/src/debug.cc
@@ -874,8 +874,9 @@ bool Debug::Load() {
// Check for caught exceptions.
if (caught_exception) return false;
- // Debugger loaded.
- debug_context_ = context;
+ // Debugger loaded, create debugger context global handle.
+ debug_context_ = Handle<Context>::cast(
+ isolate_->global_handles()->Create(*context));
return true;
}
@@ -891,7 +892,7 @@ void Debug::Unload() {
DestroyScriptCache();
// Clear debugger context global handle.
- Isolate::Current()->global_handles()->Destroy(
+ isolate_->global_handles()->Destroy(
reinterpret_cast<Object**>(debug_context_.location()));
debug_context_ = Handle<Context>();
}
« no previous file with comments | « src/bootstrapper.cc ('k') | test/cctest/cctest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698