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

Unified Diff: third_party/mojo/src/mojo/edk/system/master_connection_manager.h

Issue 1179733005: Update mojo sdk to rev bdbb0c7e396fc4044a8b194058d7a7e529715286 (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: update CommandBufferImpl (Binding::OnConnectionError is no more) Created 5 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 side-by-side diff with in-line comments
Download patch
Index: third_party/mojo/src/mojo/edk/system/master_connection_manager.h
diff --git a/third_party/mojo/src/mojo/edk/system/master_connection_manager.h b/third_party/mojo/src/mojo/edk/system/master_connection_manager.h
index d7f06b506ad873eb45e2d705e96770a16fc74772..49fd17bee1bd3e1d93b071d816504220f17b6259 100644
--- a/third_party/mojo/src/mojo/edk/system/master_connection_manager.h
+++ b/third_party/mojo/src/mojo/edk/system/master_connection_manager.h
@@ -30,9 +30,6 @@ using SlaveInfo = void*;
namespace system {
-// The master process will always have this "process identifier".
-const ProcessIdentifier kMasterProcessIdentifier = 1;
-
// The |ConnectionManager| implementation for the master process.
//
// This class is thread-safe (except that no public methods may be called from
@@ -61,22 +58,21 @@ class MOJO_SYSTEM_IMPL_EXPORT MasterConnectionManager
// |embedder::MasterProcessDelegate| to track this process. It must remain
// alive until the delegate's |OnSlaveDisconnect()| is called with it as the
// argument. |OnSlaveDisconnect()| will always be called for each slave,
- // assuming proper shutdown. |*slave_process_identifier| will be set to the
- // process identifier for the newly-added slave.
- void AddSlave(embedder::SlaveInfo slave_info,
- embedder::ScopedPlatformHandle platform_handle,
- ProcessIdentifier* slave_process_identifier);
+ // assuming proper shutdown. Returns the process identifier for the
+ // newly-added slave.
+ ProcessIdentifier AddSlave(embedder::SlaveInfo slave_info,
+ embedder::ScopedPlatformHandle platform_handle);
// Like |AddSlave()|, but allows a connection to be bootstrapped: both the
// master and slave may call |Connect()| with |connection_id| immediately (as
- // if both had already called |AllowConnect()|). Returns false if |Connect()|
- // will not be possible.
+ // if both had already called |AllowConnect()|). |connection_id| must be
+ // unique (i.e., not previously used).
// TODO(vtl): Is |AddSlave()| really needed? (It's probably mostly useful for
// tests.)
- bool AddSlaveAndBootstrap(embedder::SlaveInfo slave_info,
- embedder::ScopedPlatformHandle platform_handle,
- const ConnectionIdentifier& connection_id,
- ProcessIdentifier* slave_process_identifier);
+ ProcessIdentifier AddSlaveAndBootstrap(
+ embedder::SlaveInfo slave_info,
+ embedder::ScopedPlatformHandle platform_handle,
+ const ConnectionIdentifier& connection_id);
// |ConnectionManager| methods:
void Shutdown() override;

Powered by Google App Engine
This is Rietveld 408576698