Index: mojo/edk/system/proxy_message_pipe_endpoint.h |
diff --git a/mojo/edk/system/proxy_message_pipe_endpoint.h b/mojo/edk/system/proxy_message_pipe_endpoint.h |
index 3426869fbc3da83d8103ed5012f78fa0ca2cceb7..6e106990f35ce838abdb38bb8ac57d64b591a0f0 100644 |
--- a/mojo/edk/system/proxy_message_pipe_endpoint.h |
+++ b/mojo/edk/system/proxy_message_pipe_endpoint.h |
@@ -33,6 +33,14 @@ class MOJO_SYSTEM_IMPL_EXPORT ProxyMessagePipeEndpoint |
explicit ProxyMessagePipeEndpoint(ChannelEndpoint* channel_endpoint); |
~ProxyMessagePipeEndpoint() override; |
+ // Returns |channel_endpoint_| and resets |channel_endpoint_| to null. This |
+ // may be called at most once, after which |Close()| need not be called. |
+ // |
+ // Note: The returned |ChannelEndpoint| must have its client changed while |
+ // still under |MessagePipe|'s lock (which this must have also been called |
+ // under). |
+ scoped_refptr<ChannelEndpoint> ReleaseChannelEndpoint(); |
+ |
// |MessagePipeEndpoint| implementation: |
Type GetType() const override; |
bool OnPeerClose() override; |