| Index: webrtc/api/webrtcsessiondescriptionfactory.cc | 
| diff --git a/webrtc/api/webrtcsessiondescriptionfactory.cc b/webrtc/api/webrtcsessiondescriptionfactory.cc | 
| index 29da6f2c022bf5dfc34b525833bb4ff716ac2cac..1f811f59117afd539e2349d5010c52fd0aa0fc22 100644 | 
| --- a/webrtc/api/webrtcsessiondescriptionfactory.cc | 
| +++ b/webrtc/api/webrtcsessiondescriptionfactory.cc | 
| @@ -338,6 +338,18 @@ void WebRtcSessionDescriptionFactory::OnMessage(rtc::Message* msg) { | 
|  | 
| void WebRtcSessionDescriptionFactory::InternalCreateOffer( | 
| CreateSessionDescriptionRequest request) { | 
| +  if (session_->local_description()) { | 
| +    for (const cricket::TransportInfo& transport : | 
| +         session_->local_description()->description()->transport_infos()) { | 
| +      // If the needs-ice-restart flag is set as described by JSEP, we should | 
| +      // generate an offer with a new ufrag/password to trigger an ICE restart. | 
| +      if (session_->NeedsIceRestart(transport.content_name)) { | 
| +        request.options.transport_options[transport.content_name].ice_restart = | 
| +            true; | 
| +      } | 
| +    } | 
| +  } | 
| + | 
| cricket::SessionDescription* desc(session_desc_factory_.CreateOffer( | 
| request.options, session_->local_description() | 
| ? session_->local_description()->description() | 
|  |