Tighten RTCDatachannel creation and parameter getters
authorcommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 27 Mar 2017 18:13:19 +0000 (18:13 +0000)
committercommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 27 Mar 2017 18:13:19 +0000 (18:13 +0000)
commitf1054f3987624ef9dc287ec2b5f14857ecee5a8f
tree17d8cfcb7a5f8e72835dae32b167dbe45b788b5c
parent2fb9affc7de02d3d2ae1702fced90f00e0dd4bce
Tighten RTCDatachannel creation and parameter getters
https://bugs.webkit.org/show_bug.cgi?id=170081

Patch by Youenn Fablet <youenn@apple.com> on 2017-03-27
Reviewed by Eric Carlson.

Source/WebCore:

Covered by updated tests.

Adding some parameter checks when creating data channels.
Making some getters nullable as per the spec.

* Modules/mediastream/RTCDataChannel.h:
* Modules/mediastream/RTCDataChannel.idl:
* Modules/mediastream/RTCPeerConnection.cpp:
(WebCore::RTCPeerConnection::createDataChannel):
* Modules/mediastream/RTCPeerConnection.idl:
* Modules/mediastream/libwebrtc/LibWebRTCMediaEndpoint.cpp:
(WebCore::LibWebRTCMediaEndpoint::createDataChannel):
(WebCore::LibWebRTCMediaEndpoint::addDataChannel):
* platform/mediastream/RTCDataChannelHandler.h:
(): Deleted.

LayoutTests:

* webrtc/datachannel/basic-expected.txt:
* webrtc/datachannel/basic.html:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@214421 268f45cc-cd09-0410-ab3c-d52691b4dbfc
LayoutTests/ChangeLog
LayoutTests/webrtc/datachannel/basic-expected.txt
LayoutTests/webrtc/datachannel/basic.html
Source/WebCore/ChangeLog
Source/WebCore/Modules/mediastream/RTCDataChannel.h
Source/WebCore/Modules/mediastream/RTCDataChannel.idl
Source/WebCore/Modules/mediastream/RTCPeerConnection.cpp
Source/WebCore/Modules/mediastream/RTCPeerConnection.idl
Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCMediaEndpoint.cpp
Source/WebCore/platform/mediastream/RTCDataChannelHandler.h