OLD | NEW |
1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file |
2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
4 | 4 |
5 #include "vm/service_isolate.h" | 5 #include "vm/service_isolate.h" |
6 | 6 |
7 #include "vm/compiler.h" | 7 #include "vm/compiler.h" |
8 #include "vm/dart_api_impl.h" | 8 #include "vm/dart_api_impl.h" |
9 #include "vm/dart_entry.h" | 9 #include "vm/dart_entry.h" |
10 #include "vm/isolate.h" | 10 #include "vm/isolate.h" |
(...skipping 318 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
329 NULL, | 329 NULL, |
330 NULL, | 330 NULL, |
331 NULL, | 331 NULL, |
332 &api_flags, | 332 &api_flags, |
333 NULL, | 333 NULL, |
334 &error)); | 334 &error)); |
335 if (isolate == NULL) { | 335 if (isolate == NULL) { |
336 OS::PrintErr("vm-service: Isolate creation error: %s\n", error); | 336 OS::PrintErr("vm-service: Isolate creation error: %s\n", error); |
337 ServiceIsolate::SetServiceIsolate(NULL); | 337 ServiceIsolate::SetServiceIsolate(NULL); |
338 ServiceIsolate::FinishedInitializing(); | 338 ServiceIsolate::FinishedInitializing(); |
| 339 ServiceIsolate::FinishedExiting(); |
339 return; | 340 return; |
340 } | 341 } |
341 | 342 |
342 bool got_unwind; | 343 bool got_unwind; |
343 { | 344 { |
344 ASSERT(Isolate::Current() == NULL); | 345 ASSERT(Isolate::Current() == NULL); |
345 StartIsolateScope start_scope(isolate); | 346 StartIsolateScope start_scope(isolate); |
346 ServiceIsolate::ConstructExitMessageAndCache(isolate); | 347 ServiceIsolate::ConstructExitMessageAndCache(isolate); |
347 got_unwind = RunMain(isolate); | 348 got_unwind = RunMain(isolate); |
348 } | 349 } |
(...skipping 166 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
515 ASSERT(!result.IsNull()); | 516 ASSERT(!result.IsNull()); |
516 Dart_Port port = ILLEGAL_PORT; | 517 Dart_Port port = ILLEGAL_PORT; |
517 if (result.IsReceivePort()) { | 518 if (result.IsReceivePort()) { |
518 port = ReceivePort::Cast(result).Id(); | 519 port = ReceivePort::Cast(result).Id(); |
519 } | 520 } |
520 ASSERT(port != ILLEGAL_PORT); | 521 ASSERT(port != ILLEGAL_PORT); |
521 ServiceIsolate::SetServicePort(port); | 522 ServiceIsolate::SetServicePort(port); |
522 } | 523 } |
523 | 524 |
524 } // namespace dart | 525 } // namespace dart |
OLD | NEW |