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

Side by Side Diff: mojo/public/cpp/bindings/lib/connector.cc

Issue 272323003: Mojo: Implement support for |Foo&| mojom syntax (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 6 years, 6 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « mojo/public/cpp/bindings/lib/connector.h ('k') | mojo/public/cpp/bindings/lib/router.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "mojo/public/cpp/bindings/lib/connector.h" 5 #include "mojo/public/cpp/bindings/lib/connector.h"
6 6
7 #include <assert.h> 7 #include <assert.h>
8 #include <stdlib.h> 8 #include <stdlib.h>
9 9
10 #include "mojo/public/cpp/bindings/error_handler.h" 10 #include "mojo/public/cpp/bindings/error_handler.h"
(...skipping 20 matching lines...) Expand all
31 31
32 Connector::~Connector() { 32 Connector::~Connector() {
33 if (async_wait_id_) 33 if (async_wait_id_)
34 waiter_->CancelWait(waiter_, async_wait_id_); 34 waiter_->CancelWait(waiter_, async_wait_id_);
35 } 35 }
36 36
37 void Connector::CloseMessagePipe() { 37 void Connector::CloseMessagePipe() {
38 Close(message_pipe_.Pass()); 38 Close(message_pipe_.Pass());
39 } 39 }
40 40
41 ScopedMessagePipeHandle Connector::ReleaseMessagePipe() { 41 ScopedMessagePipeHandle Connector::PassMessagePipe() {
42 if (async_wait_id_) { 42 if (async_wait_id_) {
43 waiter_->CancelWait(waiter_, async_wait_id_); 43 waiter_->CancelWait(waiter_, async_wait_id_);
44 async_wait_id_ = 0; 44 async_wait_id_ = 0;
45 } 45 }
46 return message_pipe_.Pass(); 46 return message_pipe_.Pass();
47 } 47 }
48 48
49 bool Connector::Accept(Message* message) { 49 bool Connector::Accept(Message* message) {
50 assert(message_pipe_.is_valid()); 50 assert(message_pipe_.is_valid());
51 51
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after
126 if (rv != MOJO_RESULT_OK || 126 if (rv != MOJO_RESULT_OK ||
127 (enforce_errors_from_incoming_receiver_ && !receiver_result)) { 127 (enforce_errors_from_incoming_receiver_ && !receiver_result)) {
128 error_ = true; 128 error_ = true;
129 break; 129 break;
130 } 130 }
131 } 131 }
132 } 132 }
133 133
134 } // namespace internal 134 } // namespace internal
135 } // namespace mojo 135 } // namespace mojo
OLDNEW
« no previous file with comments | « mojo/public/cpp/bindings/lib/connector.h ('k') | mojo/public/cpp/bindings/lib/router.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698