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

Unified Diff: runtime/vm/isolate.cc

Issue 1769183003: Fix sticky error propagation from thread to isolate (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 years, 9 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 | « runtime/vm/dart_api_impl.cc ('k') | runtime/vm/object_store.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/isolate.cc
diff --git a/runtime/vm/isolate.cc b/runtime/vm/isolate.cc
index 4b1124785de7ad9019f6e452420de901fca1c876..9d54749cc6bb88aebc774dac1f9229feb0312280 100644
--- a/runtime/vm/isolate.cc
+++ b/runtime/vm/isolate.cc
@@ -2592,6 +2592,7 @@ void Isolate::UnscheduleThread(Thread* thread,
// so we create a MonitorLocker object which does not do any
// no_safepoint_scope_depth increments/decrements.
MonitorLocker ml(threads_lock(), false);
+ thread->isolate()->object_store()->SetStickyErrorFromThread(thread);
siva 2016/03/08 08:54:59 If multiple threads exit at the same time won't th
srdjan 2016/03/08 20:21:09 Modified code to allow only mutator thread to prop
if (!bypass_safepoint) {
// Ensure that the thread reports itself as being at a safepoint.
thread->EnterSafepoint();
@@ -2610,6 +2611,7 @@ void Isolate::UnscheduleThread(Thread* thread,
thread->set_execution_state(Thread::kThreadInVM);
thread->set_safepoint_state(0);
thread->clear_pending_functions();
+ thread->clear_sticky_error();
ASSERT(thread->no_safepoint_scope_depth() == 0);
// Return thread structure.
thread_registry()->ReturnThreadLocked(is_mutator, thread);
« no previous file with comments | « runtime/vm/dart_api_impl.cc ('k') | runtime/vm/object_store.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698