Throw exceptions for invalid number of channels for ConvolverNode
[WebKit-https.git] / Source / WebCore / ChangeLog
index f860c85..4e5e712 100644 (file)
@@ -1,3 +1,25 @@
+2016-07-05  David Kilzer  <ddkilzer@apple.com>
+
+        Throw exceptions for invalid number of channels for ConvolverNode
+        <https://webkit.org/b/159238>
+
+        Reviewed by Brent Fulgham.
+
+        Fix based on a Blink change (patch by <rtoy@chromium.org>):
+        <https://chromium.googlesource.com/chromium/src.git/+/0cc26bbb7175aec77910d0b47faf9f8c8a640fe5>
+
+        Also includes a related fix for ReverbConvolverStage (patch by <rtoy@chromium.org>):
+        <https://src.chromium.org/viewvc/blink?revision=157832&view=revision>
+
+        Test: webaudio/convolver-channels.html
+
+        * Modules/webaudio/ConvolverNode.cpp:
+        (WebCore::ConvolverNode::setBuffer): Throw an exception for
+        anything but 1, 2 or 4 channels.
+        * platform/audio/ReverbConvolverStage.cpp:
+        (WebCore::ReverbConvolverStage::ReverbConvolverStage): Don't read past the end of
+        the impulseResponse array.
+
 2016-07-05  Johan K. Jensen  <jj@johanjensen.dk>
 
         Web Inspector: Sending XHR with UTF8 encoded data shows garbled data in Resource sidebar