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

Unified Diff: webrtc/p2p/base/jseptransport.h

Issue 2563153002: Implement the "needs-ice-restart" logic for SetConfiguration. (Closed)
Patch Set: Created 4 years 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
Index: webrtc/p2p/base/jseptransport.h
diff --git a/webrtc/p2p/base/jseptransport.h b/webrtc/p2p/base/jseptransport.h
index 9684770bf7ad63f20f61b6f9457e9e3b3838f95f..51f75b228f9fe5a646034fde289eb46d6ccb2e25 100644
--- a/webrtc/p2p/base/jseptransport.h
+++ b/webrtc/p2p/base/jseptransport.h
@@ -288,6 +288,14 @@ class JsepTransport : public sigslot::has_slots<> {
ContentAction action,
std::string* error_desc);
+ // Set the "needs-ice-restart" flag as described in JSEP.
+ // This and the below method can be called safely from any thread as long as
+ // SetXTransportDescription is not in progress.
+ void SetNeedsIceRestartFlag();
+ // Returns true if the ICE restart flag above was set, and no ICE restart has
+ // occurred yet for this transport.
+ bool NeedsIceRestart() const;
+
void GetSslRole(rtc::SSLRole* ssl_role) const;
// TODO(deadbeef): Make this const. See comment in transportcontroller.h.
@@ -348,6 +356,8 @@ class JsepTransport : public sigslot::has_slots<> {
std::string* error_desc);
const std::string mid_;
+ // needs-ice-restart bit as described in JSEP.
+ bool needs_ice_restart_ = false;
rtc::scoped_refptr<rtc::RTCCertificate> certificate_;
rtc::SSLRole secure_role_ = rtc::SSL_CLIENT;
std::unique_ptr<rtc::SSLFingerprint> remote_fingerprint_;

Powered by Google App Engine
This is Rietveld 408576698