W3C home > Mailing lists > Public > public-webrtc@w3.org > July 2017

[webrtc-pc] setConfiguration throwing InvalidModificationError with default values

From: Soares Chen via GitHub <sysbot+gh@w3.org>
Date: Wed, 05 Jul 2017 09:57:24 +0000
To: public-webrtc@w3.org
Message-ID: <issues.opened-240598850-1499248642-sysbot+gh@w3.org>
soareschen has just created a new issue for https://github.com/w3c/webrtc-pc:

== setConfiguration throwing InvalidModificationError with default values ==
In set configuration, the fields `bundlePolicy`, `rtcpMuxPolicy`, and `iceCandidatePoolSize` are checked against the original values and if they are not the same, `InvalidModificationError` is thrown. e.g.:

> If configuration.bundlePolicy is set and its value differs from the connection's bundle policy, throw an InvalidModificationError.

But there is a problem with the wording _"if ___ is set"_. Because these fields all have default values as defined in `RTCConfiguration`, this means they are always set. So the following example would throw error:

const pc = new RTCPeerConnection({ bundlePolicy: 'max-bundle' });
// throws InvalidModificationError because provided default bundlePolicy is 'balanced'

Please view or discuss this issue at https://github.com/w3c/webrtc-pc/issues/1447 using your GitHub account
Received on Wednesday, 5 July 2017 09:57:30 UTC

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