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

Unified Diff: runtime/vm/isolate.h

Issue 861813003: Move StartIsolateScope into MessageHandler::HandleMessages (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 5 years, 11 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 | runtime/vm/isolate.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/isolate.h
diff --git a/runtime/vm/isolate.h b/runtime/vm/isolate.h
index 269ff6c5d973ea26610b39b4a0a182bf04a91e06..3019f479da0a48c6f0b8cc2e0bb8b45b0e20ca16 100644
--- a/runtime/vm/isolate.h
+++ b/runtime/vm/isolate.h
@@ -762,7 +762,10 @@ class StartIsolateScope {
public:
explicit StartIsolateScope(Isolate* new_isolate)
: new_isolate_(new_isolate), saved_isolate_(Isolate::Current()) {
- ASSERT(new_isolate_ != NULL);
+ if (new_isolate_ == NULL) {
+ // Do nothing.
+ return;
+ }
if (saved_isolate_ != new_isolate_) {
ASSERT(Isolate::Current() == NULL);
Isolate::SetCurrent(new_isolate_);
@@ -771,6 +774,10 @@ class StartIsolateScope {
}
~StartIsolateScope() {
+ if (new_isolate_ == NULL) {
+ // Do nothing.
+ return;
+ }
if (saved_isolate_ != new_isolate_) {
new_isolate_->ClearStackLimit();
Isolate::SetCurrent(saved_isolate_);
« no previous file with comments | « no previous file | runtime/vm/isolate.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698