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

Unified Diff: webrtc/p2p/base/port.cc

Issue 2099563004: Start ICE connectivity checks as soon as the first pair is pingable. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Removing debug log message, adding missing UpdateState. Created 4 years, 6 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 | « webrtc/p2p/base/port.h ('k') | webrtc/p2p/base/transport.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/p2p/base/port.cc
diff --git a/webrtc/p2p/base/port.cc b/webrtc/p2p/base/port.cc
index ca162b86faa2c92d4028b06408e30c2521391d5e..71a9e6b2b14480710f4a86e5b0a61ffdaf16d149 100644
--- a/webrtc/p2p/base/port.cc
+++ b/webrtc/p2p/base/port.cc
@@ -926,6 +926,7 @@ void Connection::set_connected(bool value) {
if (value != old_value) {
LOG_J(LS_VERBOSE, this) << "set_connected from: " << old_value << " to "
<< value;
+ SignalStateChange(this);
}
}
@@ -1235,7 +1236,7 @@ bool Connection::dead(int64_t now) const {
return now > (time_created_ms_ + MIN_CONNECTION_LIFETIME);
}
-bool Connection::stable(int64_t now) {
+bool Connection::stable(int64_t now) const {
// A connection is stable if it's RTT has converged and it isn't missing any
// responses. We should send pings at a higher rate until the RTT converges
// and whenever a ping response is missing (so that we can detect
@@ -1507,11 +1508,11 @@ void Connection::MaybeAddPrflxCandidate(ConnectionRequest* request,
SignalStateChange(this);
}
-bool Connection::rtt_converged() {
+bool Connection::rtt_converged() const {
return rtt_samples_ > (RTT_RATIO + 1);
}
-bool Connection::missing_responses(int64_t now) {
+bool Connection::missing_responses(int64_t now) const {
if (pings_since_last_response_.empty()) {
return false;
}
« no previous file with comments | « webrtc/p2p/base/port.h ('k') | webrtc/p2p/base/transport.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698