Bug 158735 - WebRTC: RTCPeerConnection::addTrack() should throw InvalidAccessError instead of InvalidModificationError.
Summary: WebRTC: RTCPeerConnection::addTrack() should throw InvalidAccessError instead...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKit Misc. (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nael Ouedraogo
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-06-14 07:02 PDT by Nael Ouedraogo
Modified: 2016-06-14 09:44 PDT (History)
4 users (show)

See Also:


Attachments
Patch (3.51 KB, patch)
2016-06-14 07:18 PDT, Nael Ouedraogo
no flags Details | Formatted Diff | Diff
Patch for landing (3.54 KB, patch)
2016-06-14 09:34 PDT, Nael Ouedraogo
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Nael Ouedraogo 2016-06-14 07:02:23 PDT
WebRTC: RTCPeerConnection::addTrack() should throw InvalidAccessError exception when track already exists in connection's set of senders.
Comment 1 Nael Ouedraogo 2016-06-14 07:18:59 PDT
Created attachment 281257 [details]
Patch
Comment 2 Eric Carlson 2016-06-14 07:46:33 PDT
Comment on attachment 281257 [details]
Patch

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

> Source/WebCore/ChangeLog:10
> +        Throw InvalidAccessError instead of InvalidModificationError when track already exists in connection's
> +        set of senders as per specification (https://w3c.github.io/webrtc-pc/#dom-rtcpeerconnection-addtrack).
> +

Please note that the results for an existing test were updated for this fix, e.g. something like:

        Updated existing test results: fast/mediastream/RTCPeerConnection-add-removeTrack-expected.txt
Comment 3 Nael Ouedraogo 2016-06-14 09:34:21 PDT
Created attachment 281262 [details]
Patch for landing
Comment 4 Nael Ouedraogo 2016-06-14 09:39:12 PDT
I landed a new patch with proposed modification in ChangeLog.

Thanks for the review.
Comment 5 WebKit Commit Bot 2016-06-14 09:44:49 PDT
Comment on attachment 281262 [details]
Patch for landing

Clearing flags on attachment: 281262

Committed r202049: <http://trac.webkit.org/changeset/202049>
Comment 6 WebKit Commit Bot 2016-06-14 09:44:53 PDT
All reviewed patches have been landed.  Closing bug.