Re: RTCSdpType "rollback" and why sdp field is needed?

On Sun, Aug 6, 2017 at 11:12 AM, Iñaki Baz Castillo <> wrote:
> Hi,
> When calling setLocalDescription() or setRemoteDescription() with {
> type: "rollback" , sdp: ??? }, what is sdp field supposed to have?
> Note that sdp field in RTCSessionDescriptionInit is not
> nullable/optional, so what is it supposed to hold when using type
> "rollback" and why is it needed at all such a sdp field?

Sorry, I understood it wrong. The spec clearly says:

> sdp of type DOMStringThe string representation of the SDP [SDP]; if type is rollback, this member is unused.

Now, if there is any Safari developer reading this (sorry, I won't
send my computer "sysdiagnose" to Apple, as your bug tracker requests,
to just report a WebRTC signaling issue), here an issue:

1) pc.setRemoteDescription(offer)

offer just includes a m=video with VP8 (not supported by Safari).

2) pc.setRemoteDescription() is then rejected. So let's try rollback:

3) pc.setRemoteDescription({ type: "rollback", sdp: "" })

4) It's rejected with "Description type incompatible with current
signaling state".

Obviously pc.signalingState was "have-remote-offer" after step 2)
above. That's why I want to perform a rollback.

If there something I misunderstand regarding the rollback mechanism?
AFAIU it's designed to be called when pc.signalingState is not
"stable", am I wrong?

Iñaki Baz Castillo

Received on Sunday, 6 August 2017 09:45:30 UTC