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

Unified Diff: runtime/lib/integers.cc

Issue 177353006: Re-apply 'Fix fromEnvironment when called from isolates.' (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 10 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
Index: runtime/lib/integers.cc
diff --git a/runtime/lib/integers.cc b/runtime/lib/integers.cc
index 4e64ea5ae04a625956daee125dd9f2c7cf296d94..07943aa8b0d71017581e4086da0f7b3167f620dd 100644
--- a/runtime/lib/integers.cc
+++ b/runtime/lib/integers.cc
@@ -239,6 +239,7 @@ DEFINE_NATIVE_ENTRY(Integer_fromEnvironment, 3) {
GET_NON_NULL_NATIVE_ARGUMENT(String, name, arguments->NativeArgAt(1));
GET_NATIVE_ARGUMENT(Integer, default_value, arguments->NativeArgAt(2));
// Call the embedder to supply us with the environment.
+ Dart_EnterScope();
Dart_EnvironmentCallback callback = isolate->environment_callback();
if (callback != NULL) {
Dart_Handle response = callback(Api::NewHandle(isolate, name.raw()));
@@ -261,6 +262,7 @@ DEFINE_NATIVE_ENTRY(Integer_fromEnvironment, 3) {
String::Handle(String::New("Illegal environment value")));
}
}
+ Dart_ExitScope();
return default_value.raw();
}
« runtime/lib/bool.cc ('K') | « runtime/lib/bool.cc ('k') | runtime/lib/string.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698