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

Unified Diff: runtime/bin/vmservice_impl.cc

Issue 1275353005: VM thread shutdown. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 5 years, 4 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/bin/vmservice_impl.cc
diff --git a/runtime/bin/vmservice_impl.cc b/runtime/bin/vmservice_impl.cc
index 89d802f4a7c6ab47342bccd731587c68f8555145..c3ac3686c896f174a82b2e7f3f36c4b03fa371f8 100644
--- a/runtime/bin/vmservice_impl.cc
+++ b/runtime/bin/vmservice_impl.cc
@@ -159,6 +159,7 @@ const char* VmService::error_msg_ = NULL;
char VmService::server_ip_[kServerIpStringBufferSize];
intptr_t VmService::server_port_ = 0;
+
bool VmService::Setup(const char* server_ip, intptr_t server_port) {
Dart_Isolate isolate = Dart_CurrentIsolate();
ASSERT(isolate != NULL);
@@ -203,7 +204,8 @@ bool VmService::Setup(const char* server_ip, intptr_t server_port) {
SHUTDOWN_ON_ERROR(library);
// Set HTTP server state.
- DartUtils::SetStringField(library, "_ip", server_ip);
+ result = DartUtils::SetStringField(library, "_ip", server_ip);
+ SHUTDOWN_ON_ERROR(result);
// If we have a port specified, start the server immediately.
bool auto_start = server_port >= 0;
if (server_port < 0) {
@@ -211,7 +213,8 @@ bool VmService::Setup(const char* server_ip, intptr_t server_port) {
// port when the HTTP server is started.
server_port = 0;
}
- DartUtils::SetIntegerField(library, "_port", server_port);
+ result = DartUtils::SetIntegerField(library, "_port", server_port);
+ SHUTDOWN_ON_ERROR(result);
result = Dart_SetField(library,
DartUtils::NewString("_autoStart"),
Dart_NewBoolean(auto_start));

Powered by Google App Engine
This is Rietveld 408576698