Bug 155535

Summary: WebRTC: Update RTCIceCandidate
Product: WebKit Reporter: Adam Bergkvist <adam.bergkvist>
Component: WebCore Misc.Assignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Normal CC: alex, commit-queue, eric.carlson
Priority: P2    
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on:    
Bug Blocks: 143211    
Attachments:
Description Flags
Proposed patch
none
Proposed patch
eric.carlson: review+
Patch for landing none

Description Adam Bergkvist 2016-03-16 00:34:07 PDT
Updates needed to better match the WebRTC 1.0 specification [1]
- "candidate" init dictionary member is required at construction
- At lest one of the "sdpMid" and "sdpMLineIndex" dictionary members must be present at construction
- sdpMid and sdpMLineIndex attributes are nullable 

[1] https://w3c.github.io/webrtc-pc/archives/20160215/webrtc.html
Comment 1 Adam Bergkvist 2016-03-16 00:57:04 PDT
Created attachment 274183 [details]
Proposed patch
Comment 2 Adam Bergkvist 2016-03-16 02:54:26 PDT
Created attachment 274185 [details]
Proposed patch

With mac build fix (unused param)
Comment 3 Eric Carlson 2016-03-16 11:59:29 PDT
Comment on attachment 274185 [details]
Proposed patch

View in context: https://bugs.webkit.org/attachment.cgi?id=274185&action=review

> Source/WebCore/ChangeLog:9
> +        In short: The "candidate" init dictionary member is required. At least one of dictionary

Nit: At least one of *the* ...

> Source/WebCore/Modules/mediastream/RTCIceCandidate.cpp:61
> +        if (!intConversionOk || result > 65535) {

Nit: you can use USHRT_MAX here.
Comment 4 Adam Bergkvist 2016-03-17 01:52:40 PDT
Created attachment 274271 [details]
Patch for landing
Comment 5 Adam Bergkvist 2016-03-17 02:15:53 PDT
Thanks for your review Eric. Both comments addressed in patch for landing.
Comment 6 WebKit Commit Bot 2016-03-17 03:52:06 PDT
Comment on attachment 274271 [details]
Patch for landing

Clearing flags on attachment: 274271

Committed r198325: <http://trac.webkit.org/changeset/198325>