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

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

Issue 1453813005: Fixing some issues with ICE restart signaling. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Created 5 years, 1 month 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/transportdescriptionfactory.cc
diff --git a/webrtc/p2p/base/transportdescriptionfactory.cc b/webrtc/p2p/base/transportdescriptionfactory.cc
index 1ddf55d4a1397c565364932ea9246184ff344bec..0342a2173ff36161b7d01ca18a8ee88cf1019ce2 100644
--- a/webrtc/p2p/base/transportdescriptionfactory.cc
+++ b/webrtc/p2p/base/transportdescriptionfactory.cc
@@ -24,11 +24,12 @@ TransportDescriptionFactory::TransportDescriptionFactory()
TransportDescription* TransportDescriptionFactory::CreateOffer(
const TransportOptions& options,
+ bool ice_restart,
const TransportDescription* current_description) const {
rtc::scoped_ptr<TransportDescription> desc(new TransportDescription());
// Generate the ICE credentials if we don't already have them.
- if (!current_description || options.ice_restart) {
+ if (!current_description || ice_restart) {
desc->ice_ufrag = rtc::CreateRandomString(ICE_UFRAG_LENGTH);
desc->ice_pwd = rtc::CreateRandomString(ICE_PWD_LENGTH);
} else {
@@ -51,6 +52,7 @@ TransportDescription* TransportDescriptionFactory::CreateOffer(
TransportDescription* TransportDescriptionFactory::CreateAnswer(
const TransportDescription* offer,
const TransportOptions& options,
+ bool ice_restart,
const TransportDescription* current_description) const {
// TODO(juberti): Figure out why we get NULL offers, and fix this upstream.
if (!offer) {
@@ -62,7 +64,7 @@ TransportDescription* TransportDescriptionFactory::CreateAnswer(
rtc::scoped_ptr<TransportDescription> desc(new TransportDescription());
// Generate the ICE credentials if we don't already have them or ice is
// being restarted.
- if (!current_description || options.ice_restart) {
+ if (!current_description || ice_restart) {
desc->ice_ufrag = rtc::CreateRandomString(ICE_UFRAG_LENGTH);
desc->ice_pwd = rtc::CreateRandomString(ICE_PWD_LENGTH);
} else {

Powered by Google App Engine
This is Rietveld 408576698