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

Unified Diff: runtime/bin/io_service.cc

Issue 43483004: Remove the reply port form the native isolate handler (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Updated to new isolate API Created 7 years, 2 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 | « runtime/bin/dartutils.h ('k') | runtime/bin/io_service_patch.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/bin/io_service.cc
diff --git a/runtime/bin/io_service.cc b/runtime/bin/io_service.cc
index 922b98c14192a53e4e5ff4daa8a866294b8aadfd..383b79f69e1ebf910d6bccbbbadca732a90613c1 100644
--- a/runtime/bin/io_service.cc
+++ b/runtime/bin/io_service.cc
@@ -28,18 +28,21 @@ namespace bin {
break;
void IOServiceCallback(Dart_Port dest_port_id,
- Dart_Port reply_port_id,
Dart_CObject* message) {
+ Dart_Port reply_port_id;
CObject* response = CObject::IllegalArgumentError();
CObjectArray request(message);
if (message->type == Dart_CObject_kArray &&
- request.Length() == 3 &&
+ request.Length() == 4 &&
request[0]->IsInt32() &&
- request[1]->IsInt32() &&
- request[2]->IsArray()) {
+ request[1]->IsSendPort() &&
+ request[2]->IsInt32() &&
+ request[3]->IsArray()) {
CObjectInt32 message_id(request[0]);
- CObjectInt32 request_id(request[1]);
- CObjectArray data(request[2]);
+ CObjectSendPort reply_port(request[1]);
+ CObjectInt32 request_id(request[2]);
+ CObjectArray data(request[3]);
+ reply_port_id = reply_port.Value();
switch (request_id.Value()) {
IO_SERVICE_REQUEST_LIST(CASE_REQUEST);
default:
@@ -75,4 +78,3 @@ void FUNCTION_NAME(IOService_NewServicePort)(Dart_NativeArguments args) {
} // namespace bin
} // namespace dart
-
« no previous file with comments | « runtime/bin/dartutils.h ('k') | runtime/bin/io_service_patch.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698