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

Unified Diff: runtime/vm/isolate_reload.cc

Issue 2748353004: Only propagate reload errors when there are Dart frames on the stack. (Closed)
Patch Set: rmacnak review Created 3 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/observatory/tests/service/bad_reload_test.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/isolate_reload.cc
diff --git a/runtime/vm/isolate_reload.cc b/runtime/vm/isolate_reload.cc
index 08f33dbc78c3a62aeb5224f02e7498584601b2c7..a0542e5907967f49e727f1a8bedce12ef1c2842b 100644
--- a/runtime/vm/isolate_reload.cc
+++ b/runtime/vm/isolate_reload.cc
@@ -636,9 +636,16 @@ void IsolateReloadContext::Reload(bool force_reload,
BackgroundCompiler::Enable();
siva 2017/03/16 18:09:45 We should probably enable the background compiler
- if (result.IsUnwindError() || result.IsUnhandledException()) {
- // If the tag handler returns with an UnwindError or an UnhandledException
- // error, propagate it and give up.
+ if (result.IsUnwindError()) {
+ // We can only propagate errors when there are Dart frames on the stack.
+ // TODO(johnmccutchan): Fix dartbug.com/29092.
+ if (thread->top_exit_frame_info() == 0) {
+ FATAL(
+ "Got an Unwind Error in the middle of a reload. "
+ "http://dartbug.com/29092");
+ }
+ // If the tag handler returns with an UnwindError error, propagate it and
+ // give up.
Exceptions::PropagateError(Error::Cast(result));
UNREACHABLE();
}
« no previous file with comments | « runtime/observatory/tests/service/bad_reload_test.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698