Index: ipc/ipc_channel_posix.cc |
=================================================================== |
--- ipc/ipc_channel_posix.cc (revision 130443) |
+++ ipc/ipc_channel_posix.cc (working copy) |
@@ -303,6 +303,7 @@ |
Mode mode, Listener* listener) |
: ChannelReader(listener), |
mode_(mode), |
+ peer_pid_(base::kNullProcessId), |
is_blocked_on_write_(false), |
waiting_connect_(true), |
message_send_bytes_written_(0), |
@@ -1081,6 +1082,7 @@ |
CHECK(descriptor.auto_close); |
} |
#endif // IPC_USES_READWRITE |
+ peer_pid_ = pid; |
listener()->OnChannelConnected(pid); |
} |
@@ -1128,6 +1130,10 @@ |
channel_impl_->set_listener(listener); |
} |
+base::ProcessId Channel::peer_pid() const { |
+ return channel_impl_->peer_pid(); |
+} |
+ |
bool Channel::Send(Message* message) { |
return channel_impl_->Send(message); |
} |