[Webkit-unassigned] [Bug 158940] WebRTC: Add support for RTCPeerConnection legacy MediaStream-based API
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Mon Jun 20 14:56:22 PDT 2016
https://bugs.webkit.org/show_bug.cgi?id=158940
--- Comment #3 from youenn fablet <youennf at gmail.com> ---
Comment on attachment 281658
--> https://bugs.webkit.org/attachment.cgi?id=281658
Proposed patch
View in context: https://bugs.webkit.org/attachment.cgi?id=281658&action=review
> Source/WebCore/Modules/mediastream/RTCPeerConnection.js:57
> + return this. at localStreams.slice();
Array.slice may be corrupted by user scripts.
The same applies to find findIndex, push, forEach, splice methods.
This should be robustified.
> Source/WebCore/Modules/mediastream/RTCPeerConnection.js:94
> + stream.getTracks().forEach(track => this. at addTrack(track, stream));
Potentially, we know that this, track and stream are of the right type.
So we could replace if statements by assert statements in the binding generated code.
That said, this might be too early to do so.
> Source/WebCore/bindings/js/JSDOMGlobalObject.cpp:87
> + JSDOMGlobalObject::GlobalPropertyInfo(clientData.builtinNames().MediaStreamPrivateName(), JSMediaStream::getConstructor(vm, this), DontDelete | ReadOnly),
It might be good to add a keyword similar to PrivateAlso for exposing DOM constructors safely to JS builtins.
Ideally, we should not need to create the constructor but just pass a getter function that would create it if needed
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.webkit.org/pipermail/webkit-unassigned/attachments/20160620/0e5537ed/attachment.html>
More information about the webkit-unassigned
mailing list