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

Unified Diff: remoting/protocol/jingle_session.cc

Issue 9316052: Log IP/port of host as well as client in Me2Me host (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: s/IpAddress/RouteChange s/end_point/remote_end_point and other nits Created 8 years, 11 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
« no previous file with comments | « remoting/protocol/connection_to_client.cc ('k') | remoting/protocol/protocol_mock_objects.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/protocol/jingle_session.cc
diff --git a/remoting/protocol/jingle_session.cc b/remoting/protocol/jingle_session.cc
index 907bc93265c497d3715f55604a723f90f194048b..6f856c0c1d9120205412eb2983df559dad3c1259 100644
--- a/remoting/protocol/jingle_session.cc
+++ b/remoting/protocol/jingle_session.cc
@@ -507,15 +507,27 @@ void JingleSession::OnChannelConnectorFinished(
void JingleSession::OnRouteChange(cricket::TransportChannel* channel,
const cricket::Candidate& candidate) {
- net::IPEndPoint end_point;
+ net::IPEndPoint remote_end_point;
if (!jingle_glue::SocketAddressToIPEndPoint(candidate.address(),
- &end_point)) {
+ &remote_end_point)) {
+ NOTREACHED();
+ return;
+ }
+
+ DCHECK(channel->GetP2PChannel());
+ DCHECK(channel->GetP2PChannel()->best_connection());
+ const cricket::Candidate& local_candidate =
+ channel->GetP2PChannel()->best_connection()->local_candidate();
+ net::IPEndPoint local_end_point;
+ if (!jingle_glue::SocketAddressToIPEndPoint(local_candidate.address(),
+ &local_end_point)) {
NOTREACHED();
return;
}
if (!route_change_callback_.is_null())
- route_change_callback_.Run(channel->name(), end_point);
+ route_change_callback_.Run(channel->name(), remote_end_point,
+ local_end_point);
}
const cricket::ContentInfo* JingleSession::GetContentInfo() const {
« no previous file with comments | « remoting/protocol/connection_to_client.cc ('k') | remoting/protocol/protocol_mock_objects.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698