Index: ipc/mojo/ipc_channel_mojo.h |
diff --git a/ipc/mojo/ipc_channel_mojo.h b/ipc/mojo/ipc_channel_mojo.h |
index 9964a8f80b74f5a82ff156d5e58c9d110208ef55..7aff3c99cca4a8386aa78bcc39e23845b193611d 100644 |
--- a/ipc/mojo/ipc_channel_mojo.h |
+++ b/ipc/mojo/ipc_channel_mojo.h |
@@ -62,7 +62,7 @@ class IPC_MOJO_EXPORT ChannelMojo : public Channel, |
public MojoBootstrap::Delegate { |
public: |
// Create ChannelMojo. A bootstrap channel is created as well. |
- // |host| must not be null. |
+ // |host| must not be null for server channels. |
static scoped_ptr<ChannelMojo> Create(ChannelMojoHost* host, |
const ChannelHandle& channel_handle, |
Mode mode, |
@@ -117,6 +117,8 @@ class IPC_MOJO_EXPORT ChannelMojo : public Channel, |
void OnPipeError(internal::MessagePipeReader* reader); |
void set_peer_pid(base::ProcessId pid) { peer_pid_ = pid; } |
+ void HostWasDestroyed(); |
viettrungluu
2014/09/25 19:38:34
I don't think this is used (or implemented).
Hajime Morrita
2014/09/25 22:00:03
Oops. Removed.
|
+ |
protected: |
ChannelMojo(ChannelMojoHost* host, |
const ChannelHandle& channel_handle, |
@@ -136,7 +138,7 @@ class IPC_MOJO_EXPORT ChannelMojo : public Channel, |
void InitControlReader(mojo::embedder::ScopedPlatformHandle handle); |
scoped_ptr<MojoBootstrap> bootstrap_; |
- ChannelMojoHost* const host_; |
+ base::WeakPtr<ChannelMojoHost> host_; |
Mode mode_; |
Listener* listener_; |
base::ProcessId peer_pid_; |