Calling createPattern with a broken image must throw an invalidstate error
authorcabanier@adobe.com <cabanier@adobe.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 1 May 2014 08:33:47 +0000 (08:33 +0000)
committercabanier@adobe.com <cabanier@adobe.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 1 May 2014 08:33:47 +0000 (08:33 +0000)
commit59ec4d6150345d66a3a8969eef1c9df9d980b765
tree13e805a55572f3134fd827b9c8b12d76aabb6b77
parent925cc8e19dbada582cd6fc07eba3ba16a74aa379
Calling createPattern with a broken image must throw an invalidstate error
https://bugs.webkit.org/show_bug.cgi?id=132407

Reviewed by Dirk Schulze.

Source/WebCore:
Per the WebIDL spec, passing non-finite parameter to a method that
takes doubles, should generate a type error.

Tests:
* canvas/philip/tests/2d.imageData.create2.nonfinite.html:
* fast/canvas/canvas-2d-imageData-create-nonfinite.html:

* html/canvas/CanvasRenderingContext2D.cpp:
(WebCore::CanvasRenderingContext2D::createImageData):

LayoutTests:
* canvas/philip/tests/2d.imageData.create2.nonfinite.html:
* fast/canvas/canvas-2d-imageData-create-nonfinite-expected.txt:
* fast/canvas/resources/canvas-2d-imageData-create-nonfinite.js:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@168092 268f45cc-cd09-0410-ab3c-d52691b4dbfc
LayoutTests/ChangeLog
LayoutTests/canvas/philip/tests/2d.imageData.create2.nonfinite.html
LayoutTests/fast/canvas/canvas-2d-imageData-create-nonfinite-expected.txt
LayoutTests/fast/canvas/resources/canvas-2d-imageData-create-nonfinite.js
Source/WebCore/ChangeLog
Source/WebCore/html/canvas/CanvasRenderingContext2D.cpp