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

Side by Side Diff: mojo/public/platform/native/system_thunks.cc

Issue 324783002: Mojo: Add a MojoCreateMessagePipeOptions struct parameter to MojoCreateMessagePipe. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebased 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/platform/native/system_thunks.h ('k') | mojo/system/core.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/platform/native/system_thunks.h" 5 #include "mojo/public/platform/native/system_thunks.h"
6 6
7 #include <assert.h> 7 #include <assert.h>
8 8
9 extern "C" { 9 extern "C" {
10 10
(...skipping 17 matching lines...) Expand all
28 } 28 }
29 29
30 MojoResult MojoWaitMany(const MojoHandle* handles, 30 MojoResult MojoWaitMany(const MojoHandle* handles,
31 const MojoWaitFlags* flags, 31 const MojoWaitFlags* flags,
32 uint32_t num_handles, 32 uint32_t num_handles,
33 MojoDeadline deadline) { 33 MojoDeadline deadline) {
34 assert(g_thunks.WaitMany); 34 assert(g_thunks.WaitMany);
35 return g_thunks.WaitMany(handles, flags, num_handles, deadline); 35 return g_thunks.WaitMany(handles, flags, num_handles, deadline);
36 } 36 }
37 37
38 MojoResult MojoCreateMessagePipe(MojoHandle* message_pipe_handle0, 38 MojoResult MojoCreateMessagePipe(const MojoCreateMessagePipeOptions* options,
39 MojoHandle* message_pipe_handle0,
39 MojoHandle* message_pipe_handle1) { 40 MojoHandle* message_pipe_handle1) {
40 assert(g_thunks.CreateMessagePipe); 41 assert(g_thunks.CreateMessagePipe);
41 return g_thunks.CreateMessagePipe(message_pipe_handle0, message_pipe_handle1); 42 return g_thunks.CreateMessagePipe(options, message_pipe_handle0,
43 message_pipe_handle1);
42 } 44 }
43 45
44 MojoResult MojoWriteMessage(MojoHandle message_pipe_handle, 46 MojoResult MojoWriteMessage(MojoHandle message_pipe_handle,
45 const void* bytes, 47 const void* bytes,
46 uint32_t num_bytes, 48 uint32_t num_bytes,
47 const MojoHandle* handles, 49 const MojoHandle* handles,
48 uint32_t num_handles, 50 uint32_t num_handles,
49 MojoWriteMessageFlags flags) { 51 MojoWriteMessageFlags flags) {
50 assert(g_thunks.WriteMessage); 52 assert(g_thunks.WriteMessage);
51 return g_thunks.WriteMessage(message_pipe_handle, bytes, num_bytes, handles, 53 return g_thunks.WriteMessage(message_pipe_handle, bytes, num_bytes, handles,
(...skipping 107 matching lines...) Expand 10 before | Expand all | Expand 10 after
159 #endif 161 #endif
160 162
161 extern "C" THUNK_EXPORT size_t MojoSetSystemThunks( 163 extern "C" THUNK_EXPORT size_t MojoSetSystemThunks(
162 const MojoSystemThunks* system_thunks) { 164 const MojoSystemThunks* system_thunks) {
163 if (system_thunks->size >= sizeof(g_thunks)) 165 if (system_thunks->size >= sizeof(g_thunks))
164 g_thunks = *system_thunks; 166 g_thunks = *system_thunks;
165 return sizeof(g_thunks); 167 return sizeof(g_thunks);
166 } 168 }
167 169
168 } // extern "C" 170 } // extern "C"
OLDNEW
« no previous file with comments | « mojo/public/platform/native/system_thunks.h ('k') | mojo/system/core.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698