W3C home > Mailing lists > Public > public-webrtc@w3.org > March 2019

[webrtc-pc] createOffer does not guard against "have-remote-offer" (#2145)

From: Jan-Ivar Bruaroey via GitHub <sysbot+gh@w3.org>
Date: Tue, 26 Mar 2019 20:18:25 +0000
To: public-webrtc@w3.org
Message-ID: <issues.opened-425628882-1553631503-sysbot+gh@w3.org>
jan-ivar has just created a new issue for https://github.com/w3c/webrtc-pc:

== createOffer does not guard against "have-remote-offer" ==
There's no limit on when *createOffer* may be called today. *"Unlike createOffer, repeated call to createAnswer cannot be used again with setLocalDescription because doing so is invalid in stable state."* https://github.com/w3c/webrtc-pc/issues/1183#issue-227312645

It seems the reason is *createOffer* may be called from `"stable"` *and* `"have-local-offer"`.

But @docfaraday pointed out to me that calling *createOffer* in `"have-remote-offer"` makes no sense, and would be difficult to implement. So we should guard against that.

I'll add a PR to reject with ` InvalidStateError` (which is what *createAnswer* uses today).

Please view or discuss this issue at https://github.com/w3c/webrtc-pc/issues/2145 using your GitHub account
Received on Tuesday, 26 March 2019 20:18:26 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 19:18:47 UTC