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

Unified Diff: runtime/bin/dartutils.cc

Issue 13842019: - Check for error when creating the source string. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/bin/dartutils.cc
===================================================================
--- runtime/bin/dartutils.cc (revision 21785)
+++ runtime/bin/dartutils.cc (working copy)
@@ -391,6 +391,9 @@
return Dart_LoadScriptFromSnapshot(text_buffer, len);
} else {
Dart_Handle source = Dart_NewStringFromUTF8(text_buffer, len);
+ if (Dart_IsError(source)) {
+ return source;
+ }
return Dart_LoadScript(resolved_script_uri, source, 0, 0);
Mads Ager (google) 2013/04/22 13:05:41 I thought all of the APIs had the property that th
Ivan Posva 2013/04/22 13:12:42 Dart_LoadScript does return an error if it gets un
Mads Ager (google) 2013/04/22 13:13:48 I see. Thanks! :)
}
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698