Closed Bug 1456417 Opened Last year Closed 10 months ago

addIceCandidate without sdpMLineIndex incorrectly assumes sdpMLineIndex = 0

Categories

(Core :: WebRTC: Signaling, defect, P2)

defect

Tracking

()

RESOLVED FIXED
mozilla65
Tracking Status
firefox65 --- fixed

People

(Reporter: fippo, Assigned: drno)

Details

Attachments

(1 file, 1 obsolete file)

steps to reproduce:
1. run https://jsfiddle.net/1xxf4pnh/
2. observe this exception in the console: 
DOMException: Mismatch between mid and level - "sdparta_1" is not the mid for level 0; "sdparta_0" is
 sdparta_1

The fiddle removes the sdpMLineIndex and it looks like this gets interpreted as 0. Passing 0 does not help either.

The spec seems to prefer sdpMid over sdpMLineIndex:
https://w3c.github.io/webrtc-pc/#dom-rtcpeerconnection-addicecandidate
but the Firefox behaviour suggests it is the other way round.

Not a regression, happens in 52/ESR too as far as I can see.
err... passing "null" does not help either. Passing "0" would be wrong.
Yeah, I think the spec used to mandate this behavior?
The spec may have switched opinion on what is the preferred thing but interpreting nothing as 0 would be wrong too :-)
Rank: 19
Priority: -- → P2
Attachment #9022097 - Attachment is obsolete: true
Pushed by nohlmeier@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/9c729de094ae
made MLineIndex nullable. r=bwc,smaug
Created web-platform-tests PR https://github.com/web-platform-tests/wpt/pull/14047 for changes under testing/web-platform/tests
Upstream web-platform-tests status checks passed, PR will merge once commit reaches central.
https://hg.mozilla.org/mozilla-central/rev/9c729de094ae
Status: NEW → RESOLVED
Closed: 10 months ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla65
Upstream PR merged
You need to log in before you can comment on or make changes to this bug.