Index: webrtc/p2p/base/p2ptransportchannel.cc |
diff --git a/webrtc/p2p/base/p2ptransportchannel.cc b/webrtc/p2p/base/p2ptransportchannel.cc |
index 5f858c4858f952174b878891a875648bbd69de43..e6b091180c44266d620323ecd38e7357a58529cd 100644 |
--- a/webrtc/p2p/base/p2ptransportchannel.cc |
+++ b/webrtc/p2p/base/p2ptransportchannel.cc |
@@ -1010,19 +1010,8 @@ bool P2PTransportChannel::GetStats(ConnectionInfos *infos) { |
infos->clear(); |
for (Connection* connection : connections_) { |
- ConnectionInfo info = connection->stats(); |
- info.best_connection = (selected_connection_ == connection); |
- info.receiving = connection->receiving(); |
- info.writable = (connection->write_state() == Connection::STATE_WRITABLE); |
- info.timeout = |
- (connection->write_state() == Connection::STATE_WRITE_TIMEOUT); |
- info.new_connection = !connection->reported(); |
+ infos->push_back(connection->stats(selected_connection_ == connection)); |
Taylor Brandstetter
2016/12/23 18:59:45
I'd prefer if "best_connection" was set here, rath
hbos
2016/12/27 10:24:34
Done.
|
connection->set_reported(true); |
- info.rtt = connection->rtt(); |
- info.local_candidate = connection->local_candidate(); |
- info.remote_candidate = connection->remote_candidate(); |
- info.key = connection; |
- infos->push_back(info); |
} |
return true; |
@@ -1559,7 +1548,7 @@ bool P2PTransportChannel::IsPingable(const Connection* conn, |
} |
// A failed connection will not be pinged. |
- if (conn->state() == Connection::STATE_FAILED) { |
+ if (conn->state() == IceCandidatePairState::FAILED) { |
return false; |
} |