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

Side by Side Diff: mojo/edk/system/message_pipe.h

Issue 795593004: Update mojo sdk to rev cc531b32182099a5a034a99daff35ed5d38a61c8 (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: More workarounds for MSVC Created 5 years, 11 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
« no previous file with comments | « mojo/edk/system/message_in_transit.cc ('k') | mojo/edk/system/message_pipe.cc » ('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 #ifndef MOJO_EDK_SYSTEM_MESSAGE_PIPE_H_ 5 #ifndef MOJO_EDK_SYSTEM_MESSAGE_PIPE_H_
6 #define MOJO_EDK_SYSTEM_MESSAGE_PIPE_H_ 6 #define MOJO_EDK_SYSTEM_MESSAGE_PIPE_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 #include <stdint.h> 9 #include <stdint.h>
10 10
(...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after
114 void* destination, 114 void* destination,
115 size_t* actual_size, 115 size_t* actual_size,
116 embedder::PlatformHandleVector* platform_handles); 116 embedder::PlatformHandleVector* platform_handles);
117 117
118 // |ChannelEndpointClient| methods: 118 // |ChannelEndpointClient| methods:
119 bool OnReadMessage(unsigned port, MessageInTransit* message) override; 119 bool OnReadMessage(unsigned port, MessageInTransit* message) override;
120 void OnDetachFromChannel(unsigned port) override; 120 void OnDetachFromChannel(unsigned port) override;
121 121
122 private: 122 private:
123 MessagePipe(); 123 MessagePipe();
124 virtual ~MessagePipe(); 124 ~MessagePipe() override;
125 125
126 // This is used internally by |WriteMessage()| and by |OnReadMessage()|. 126 // This is used internally by |WriteMessage()| and by |OnReadMessage()|.
127 // |transports| may be non-null only if it's nonempty and |message| has no 127 // |transports| may be non-null only if it's nonempty and |message| has no
128 // dispatchers attached. Must be called with |lock_| held. 128 // dispatchers attached. Must be called with |lock_| held.
129 MojoResult EnqueueMessageNoLock(unsigned port, 129 MojoResult EnqueueMessageNoLock(unsigned port,
130 scoped_ptr<MessageInTransit> message, 130 scoped_ptr<MessageInTransit> message,
131 std::vector<DispatcherTransport>* transports); 131 std::vector<DispatcherTransport>* transports);
132 132
133 // Helper for |EnqueueMessageNoLock()|. Must be called with |lock_| held. 133 // Helper for |EnqueueMessageNoLock()|. Must be called with |lock_| held.
134 MojoResult AttachTransportsNoLock( 134 MojoResult AttachTransportsNoLock(
135 unsigned port, 135 unsigned port,
136 MessageInTransit* message, 136 MessageInTransit* message,
137 std::vector<DispatcherTransport>* transports); 137 std::vector<DispatcherTransport>* transports);
138 138
139 base::Lock lock_; // Protects the following members. 139 base::Lock lock_; // Protects the following members.
140 scoped_ptr<MessagePipeEndpoint> endpoints_[2]; 140 scoped_ptr<MessagePipeEndpoint> endpoints_[2];
141 141
142 DISALLOW_COPY_AND_ASSIGN(MessagePipe); 142 DISALLOW_COPY_AND_ASSIGN(MessagePipe);
143 }; 143 };
144 144
145 } // namespace system 145 } // namespace system
146 } // namespace mojo 146 } // namespace mojo
147 147
148 #endif // MOJO_EDK_SYSTEM_MESSAGE_PIPE_H_ 148 #endif // MOJO_EDK_SYSTEM_MESSAGE_PIPE_H_
OLDNEW
« no previous file with comments | « mojo/edk/system/message_in_transit.cc ('k') | mojo/edk/system/message_pipe.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698