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

Unified Diff: runtime/bin/builtin_natives.cc

Issue 9657001: Start using Dart_PropagateError in the runtime/bin directory. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 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 | « no previous file | runtime/bin/dartutils.h » ('j') | runtime/bin/dartutils.h » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/bin/builtin_natives.cc
===================================================================
--- runtime/bin/builtin_natives.cc (revision 5191)
+++ runtime/bin/builtin_natives.cc (working copy)
@@ -101,7 +101,11 @@
const char* cstring = NULL;
Dart_Handle result = Dart_StringToCString(str, &cstring);
if (Dart_IsError(result)) {
- cstring = Dart_GetError(result);
+ // TODO(turnidge): Consider propagating some errors here. What if
+ // an isolate gets interrupted by the embedder in the middle of
+ // Dart_StringToCString? We need to make sure not to swallow the
+ // interrupt.
+ cstring = Dart_GetError(result);
}
fprintf(out, "%s\n", cstring);
fflush(out);
« no previous file with comments | « no previous file | runtime/bin/dartutils.h » ('j') | runtime/bin/dartutils.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698