WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
[patch]
Patch
bug-225263-20210501091538.patch (text/plain), 43.64 KB, created by
Sam Weinig
on 2021-05-01 09:15:39 PDT
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Sam Weinig
Created:
2021-05-01 09:15:39 PDT
Size:
43.64 KB
patch
obsolete
>Index: Source/WebCore/ChangeLog >=================================================================== >--- Source/WebCore/ChangeLog (revision 276869) >+++ Source/WebCore/ChangeLog (working copy) >@@ -1,3 +1,19 @@ >+2021-04-30 Sam Weinig <weinig@apple.com> >+ >+ Update operations in CanvasImageData.idl to use long rather than float as per spec >+ https://bugs.webkit.org/show_bug.cgi?id=225263 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ Use `[EnforceRange] long` to match the current HTML spec. >+ >+ * html/canvas/CanvasImageData.idl: >+ * html/canvas/CanvasRenderingContext2DBase.cpp: >+ (WebCore::CanvasRenderingContext2DBase::createImageData const): >+ (WebCore::CanvasRenderingContext2DBase::getImageData const): >+ (WebCore::CanvasRenderingContext2DBase::putImageData): >+ * html/canvas/CanvasRenderingContext2DBase.h: >+ > 2021-04-30 Cameron McCormack <heycam@apple.com> > > Defend further against a PlatformCALayer's owner becoming null in PlatformCALayerCocoa::drawLayerContents. >Index: Source/WebCore/html/canvas/CanvasImageData.idl >=================================================================== >--- Source/WebCore/html/canvas/CanvasImageData.idl (revision 276819) >+++ Source/WebCore/html/canvas/CanvasImageData.idl (working copy) >@@ -25,12 +25,10 @@ > > // https://html.spec.whatwg.org/multipage/canvas.html#canvasimagedata > interface mixin CanvasImageData { >- // FIXME: All the float arguments below should be longs. >- > // pixel manipulation >- ImageData createImageData(float sw, float sh); >+ ImageData createImageData([EnforceRange] long sw, [EnforceRange] long sh); > ImageData createImageData(ImageData imagedata); >- ImageData getImageData(float sx, float sy, float sw, float sh); >- undefined putImageData(ImageData imagedata, float dx, float dy); >- undefined putImageData(ImageData imagedata, float dx, float dy, float dirtyX, float dirtyY, float dirtyWidth, float dirtyHeight); >+ ImageData getImageData([EnforceRange] long sx, [EnforceRange] long sy, [EnforceRange] long sw, [EnforceRange] long sh); >+ undefined putImageData(ImageData imagedata, [EnforceRange] long dx, [EnforceRange] long dy); >+ undefined putImageData(ImageData imagedata, [EnforceRange] long dx, [EnforceRange] long dy, [EnforceRange] long dirtyX, [EnforceRange] long dirtyY, [EnforceRange] long dirtyWidth, [EnforceRange] long dirtyHeight); > }; >Index: Source/WebCore/html/canvas/CanvasRenderingContext2DBase.cpp >=================================================================== >--- Source/WebCore/html/canvas/CanvasRenderingContext2DBase.cpp (revision 276819) >+++ Source/WebCore/html/canvas/CanvasRenderingContext2DBase.cpp (working copy) >@@ -2164,25 +2164,16 @@ RefPtr<ImageData> CanvasRenderingContext > return createEmptyImageData(imageData.size()); > } > >-ExceptionOr<RefPtr<ImageData>> CanvasRenderingContext2DBase::createImageData(float sw, float sh) const >+ExceptionOr<RefPtr<ImageData>> CanvasRenderingContext2DBase::createImageData(int sw, int sh) const > { > if (!sw || !sh) > return Exception { IndexSizeError }; > >- FloatSize logicalSize(std::abs(sw), std::abs(sh)); >- if (!logicalSize.isExpressibleAsIntSize()) >- return nullptr; >- >- IntSize size = expandedIntSize(logicalSize); >- if (size.width() < 1) >- size.setWidth(1); >- if (size.height() < 1) >- size.setHeight(1); >- >+ IntSize size { std::abs(sw), std::abs(sh) }; > return createEmptyImageData(size); > } > >-ExceptionOr<RefPtr<ImageData>> CanvasRenderingContext2DBase::getImageData(float sx, float sy, float sw, float sh) const >+ExceptionOr<RefPtr<ImageData>> CanvasRenderingContext2DBase::getImageData(int sx, int sy, int sw, int sh) const > { > if (!canvasBase().originClean()) { > static NeverDestroyed<String> consoleMessage(MAKE_STATIC_STRING_IMPL("Unable to get image data from canvas because the canvas has been tainted by cross-origin data.")); >@@ -2202,15 +2193,7 @@ ExceptionOr<RefPtr<ImageData>> CanvasRen > sh = -sh; > } > >- FloatRect logicalRect(sx, sy, sw, sh); >- if (logicalRect.width() < 1) >- logicalRect.setWidth(1); >- if (logicalRect.height() < 1) >- logicalRect.setHeight(1); >- if (!logicalRect.isExpressibleAsIntRect()) >- return nullptr; >- >- IntRect imageDataRect = enclosingIntRect(logicalRect); >+ IntRect imageDataRect { sx, sy, sw, sh }; > > ImageBuffer* buffer = canvasBase().buffer(); > if (!buffer) >@@ -2226,12 +2209,12 @@ ExceptionOr<RefPtr<ImageData>> CanvasRen > return imageData; > } > >-void CanvasRenderingContext2DBase::putImageData(ImageData& data, float dx, float dy) >+void CanvasRenderingContext2DBase::putImageData(ImageData& data, int dx, int dy) > { > putImageData(data, dx, dy, 0, 0, data.width(), data.height()); > } > >-void CanvasRenderingContext2DBase::putImageData(ImageData& data, float dx, float dy, float dirtyX, float dirtyY, float dirtyWidth, float dirtyHeight) >+void CanvasRenderingContext2DBase::putImageData(ImageData& data, int dx, int dy, int dirtyX, int dirtyY, int dirtyWidth, int dirtyHeight) > { > ImageBuffer* buffer = canvasBase().buffer(); > if (!buffer) >@@ -2250,20 +2233,20 @@ void CanvasRenderingContext2DBase::putIm > dirtyHeight = -dirtyHeight; > } > >- FloatRect clipRect(dirtyX, dirtyY, dirtyWidth, dirtyHeight); >- clipRect.intersect(IntRect(0, 0, data.width(), data.height())); >- IntSize destOffset(static_cast<int>(dx), static_cast<int>(dy)); >- IntRect destRect = enclosingIntRect(clipRect); >+ IntRect clipRect { dirtyX, dirtyY, dirtyWidth, dirtyHeight }; >+ clipRect.intersect(IntRect { 0, 0, data.width(), data.height() }); >+ IntSize destOffset { dx, dy }; >+ IntRect destRect = clipRect; > destRect.move(destOffset); >- destRect.intersect(IntRect(IntPoint(), buffer->logicalSize())); >+ destRect.intersect(IntRect { { }, buffer->logicalSize() }); > if (destRect.isEmpty()) > return; >- IntRect sourceRect(destRect); >+ IntRect sourceRect { destRect }; > sourceRect.move(-destOffset); >- sourceRect.intersect(IntRect(0, 0, data.width(), data.height())); >+ sourceRect.intersect(IntRect { 0, 0, data.width(), data.height() }); > > if (!sourceRect.isEmpty()) >- buffer->putImageData(AlphaPremultiplication::Unpremultiplied, data, sourceRect, IntPoint(destOffset)); >+ buffer->putImageData(AlphaPremultiplication::Unpremultiplied, data, sourceRect, IntPoint { destOffset }); > > didDraw(FloatRect { destRect }, { }); // ignore transform, shadow and clip > } >Index: Source/WebCore/html/canvas/CanvasRenderingContext2DBase.h >=================================================================== >--- Source/WebCore/html/canvas/CanvasRenderingContext2DBase.h (revision 276819) >+++ Source/WebCore/html/canvas/CanvasRenderingContext2DBase.h (working copy) >@@ -188,10 +188,10 @@ public: > ExceptionOr<RefPtr<CanvasPattern>> createPattern(CanvasImageSource&&, const String& repetition); > > RefPtr<ImageData> createImageData(ImageData&) const; >- ExceptionOr<RefPtr<ImageData>> createImageData(float width, float height) const; >- ExceptionOr<RefPtr<ImageData>> getImageData(float sx, float sy, float sw, float sh) const; >- void putImageData(ImageData&, float dx, float dy); >- void putImageData(ImageData&, float dx, float dy, float dirtyX, float dirtyY, float dirtyWidth, float dirtyHeight); >+ ExceptionOr<RefPtr<ImageData>> createImageData(int width, int height) const; >+ ExceptionOr<RefPtr<ImageData>> getImageData(int sx, int sy, int sw, int sh) const; >+ void putImageData(ImageData&, int dx, int dy); >+ void putImageData(ImageData&, int dx, int dy, int dirtyX, int dirtyY, int dirtyWidth, int dirtyHeight); > > static constexpr float webkitBackingStorePixelRatio() { return 1; } > >Index: LayoutTests/ChangeLog >=================================================================== >--- LayoutTests/ChangeLog (revision 276819) >+++ LayoutTests/ChangeLog (working copy) >@@ -1,3 +1,27 @@ >+2021-05-01 Sam Weinig <weinig@apple.com> >+ >+ Update operations in CanvasImageData.idl to use long rather than float as per spec >+ https://bugs.webkit.org/show_bug.cgi?id=225263 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ * canvas/philip/tests/2d.imageData.create2.tiny-expected.txt: >+ * canvas/philip/tests/2d.imageData.get.tiny-expected.txt: >+ Update results, which now don't pass, to match the spec behavior. >+ >+ * fast/canvas/canvas-2d-imageData-create-nonfinite-expected.txt: >+ * fast/canvas/canvas-crash.html: >+ * fast/canvas/canvas-getImageData-invalid-expected.txt: >+ * fast/canvas/canvas-getImageData-invalid-result-buffer-crash.html: >+ * fast/canvas/canvas-getImageData-invalid.html: >+ * fast/canvas/canvas-getImageData-large-crash-expected.txt: >+ * fast/canvas/canvas-getImageData-rounding-expected.txt: >+ * fast/canvas/canvas-getImageData-rounding.html: >+ * fast/canvas/canvas-putImageData-expected.txt: >+ * fast/canvas/canvas-putImageData.js: >+ * fast/canvas/resources/canvas-2d-imageData-create-nonfinite.js: >+ Update tests and results to match spec behavior. >+ > 2021-04-29 Zalan Bujtas <zalan@apple.com> > > Floating object are not removed from the initial containing block >Index: LayoutTests/canvas/philip/tests/2d.imageData.create2.tiny-expected.txt >=================================================================== >--- LayoutTests/canvas/philip/tests/2d.imageData.create2.tiny-expected.txt (revision 276819) >+++ LayoutTests/canvas/philip/tests/2d.imageData.create2.tiny-expected.txt (working copy) >@@ -1 +1 @@ >-Passed >+Aborted with exception: The index is not in the allowed range. >Index: LayoutTests/canvas/philip/tests/2d.imageData.get.tiny-expected.txt >=================================================================== >--- LayoutTests/canvas/philip/tests/2d.imageData.get.tiny-expected.txt (revision 276819) >+++ LayoutTests/canvas/philip/tests/2d.imageData.get.tiny-expected.txt (working copy) >@@ -1 +1 @@ >-Passed >+Aborted with exception: The index is not in the allowed range. >Index: LayoutTests/fast/canvas/canvas-2d-imageData-create-nonfinite-expected.txt >=================================================================== >--- LayoutTests/fast/canvas/canvas-2d-imageData-create-nonfinite-expected.txt (revision 276819) >+++ LayoutTests/fast/canvas/canvas-2d-imageData-create-nonfinite-expected.txt (working copy) >@@ -3,13 +3,13 @@ Test the argument bounds of canvas creat > On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE". > > >-PASS ctx.createImageData(Infinity, Infinity) threw exception TypeError: The provided value is non-finite. >-PASS ctx.createImageData(Infinity, 10) threw exception TypeError: The provided value is non-finite. >-PASS ctx.createImageData(-Infinity, 10) threw exception TypeError: The provided value is non-finite. >-PASS ctx.createImageData(10, Infinity) threw exception TypeError: The provided value is non-finite. >-PASS ctx.createImageData(10, -Infinity) threw exception TypeError: The provided value is non-finite. >-PASS ctx.createImageData(NaN, 10) threw exception TypeError: The provided value is non-finite. >-PASS ctx.createImageData(10, NaN) threw exception TypeError: The provided value is non-finite. >+PASS ctx.createImageData(Infinity, Infinity) threw exception TypeError: Value Infinity is outside the range [-2147483648, 2147483647]. >+PASS ctx.createImageData(Infinity, 10) threw exception TypeError: Value Infinity is outside the range [-2147483648, 2147483647]. >+PASS ctx.createImageData(-Infinity, 10) threw exception TypeError: Value -Infinity is outside the range [-2147483648, 2147483647]. >+PASS ctx.createImageData(10, Infinity) threw exception TypeError: Value Infinity is outside the range [-2147483648, 2147483647]. >+PASS ctx.createImageData(10, -Infinity) threw exception TypeError: Value -Infinity is outside the range [-2147483648, 2147483647]. >+PASS ctx.createImageData(NaN, 10) threw exception TypeError: Value NaN is outside the range [-2147483648, 2147483647]. >+PASS ctx.createImageData(10, NaN) threw exception TypeError: Value NaN is outside the range [-2147483648, 2147483647]. > PASS successfullyParsed is true > > TEST COMPLETE >Index: LayoutTests/fast/canvas/canvas-crash.html >=================================================================== >--- LayoutTests/fast/canvas/canvas-crash.html (revision 276819) >+++ LayoutTests/fast/canvas/canvas-crash.html (working copy) >@@ -13,7 +13,7 @@ if (window.testRunner) > function canvastest() > { > var ctx = document.getCSSCanvasContext("2d", "canvastest", 13951, 11138); >- ctx.putImageData(ctx.getImageData(1431655766, document.getElementById("a").appendChild(document.createElement("media")).clientWidth, 4096, -1024), 128, -65535, 127, -2147483648, 1111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111, -1111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111); >+ ctx.putImageData(ctx.getImageData(1431655766, document.getElementById("a").appendChild(document.createElement("media")).clientWidth, 4096, -1024), 128, -65535, 127, -2147483648, 2147483647, -2147483648); > } > > canvastest(); >Index: LayoutTests/fast/canvas/canvas-getImageData-invalid-expected.txt >=================================================================== >--- LayoutTests/fast/canvas/canvas-getImageData-invalid-expected.txt (revision 276819) >+++ LayoutTests/fast/canvas/canvas-getImageData-invalid-expected.txt (working copy) >@@ -3,18 +3,18 @@ Test the handling of invalid arguments i > On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE". > > >-PASS ctx.getImageData(NaN, 10, 10, 10) threw exception TypeError: The provided value is non-finite. >-PASS ctx.getImageData(10, NaN, 10, 10) threw exception TypeError: The provided value is non-finite. >-PASS ctx.getImageData(10, 10, NaN, 10) threw exception TypeError: The provided value is non-finite. >-PASS ctx.getImageData(10, 10, 10, NaN) threw exception TypeError: The provided value is non-finite. >-PASS ctx.getImageData(Infinity, 10, 10, 10) threw exception TypeError: The provided value is non-finite. >-PASS ctx.getImageData(10, Infinity, 10, 10) threw exception TypeError: The provided value is non-finite. >-PASS ctx.getImageData(10, 10, Infinity, 10) threw exception TypeError: The provided value is non-finite. >-PASS ctx.getImageData(10, 10, 10, Infinity) threw exception TypeError: The provided value is non-finite. >-PASS ctx.getImageData(undefined, 10, 10, 10) threw exception TypeError: The provided value is non-finite. >-PASS ctx.getImageData(10, undefined, 10, 10) threw exception TypeError: The provided value is non-finite. >-PASS ctx.getImageData(10, 10, undefined, 10) threw exception TypeError: The provided value is non-finite. >-PASS ctx.getImageData(10, 10, 10, undefined) threw exception TypeError: The provided value is non-finite. >+PASS ctx.getImageData(NaN, 10, 10, 10) threw exception TypeError: Value NaN is outside the range [-2147483648, 2147483647]. >+PASS ctx.getImageData(10, NaN, 10, 10) threw exception TypeError: Value NaN is outside the range [-2147483648, 2147483647]. >+PASS ctx.getImageData(10, 10, NaN, 10) threw exception TypeError: Value NaN is outside the range [-2147483648, 2147483647]. >+PASS ctx.getImageData(10, 10, 10, NaN) threw exception TypeError: Value NaN is outside the range [-2147483648, 2147483647]. >+PASS ctx.getImageData(Infinity, 10, 10, 10) threw exception TypeError: Value Infinity is outside the range [-2147483648, 2147483647]. >+PASS ctx.getImageData(10, Infinity, 10, 10) threw exception TypeError: Value Infinity is outside the range [-2147483648, 2147483647]. >+PASS ctx.getImageData(10, 10, Infinity, 10) threw exception TypeError: Value Infinity is outside the range [-2147483648, 2147483647]. >+PASS ctx.getImageData(10, 10, 10, Infinity) threw exception TypeError: Value Infinity is outside the range [-2147483648, 2147483647]. >+PASS ctx.getImageData(undefined, 10, 10, 10) threw exception TypeError: Value NaN is outside the range [-2147483648, 2147483647]. >+PASS ctx.getImageData(10, undefined, 10, 10) threw exception TypeError: Value NaN is outside the range [-2147483648, 2147483647]. >+PASS ctx.getImageData(10, 10, undefined, 10) threw exception TypeError: Value NaN is outside the range [-2147483648, 2147483647]. >+PASS ctx.getImageData(10, 10, 10, undefined) threw exception TypeError: Value NaN is outside the range [-2147483648, 2147483647]. > PASS ctx.getImageData(10, 10, 0, 10) threw exception IndexSizeError: The index is not in the allowed range.. > PASS ctx.getImageData(10, 10, 10, 0) threw exception IndexSizeError: The index is not in the allowed range.. > PASS successfullyParsed is true >Index: LayoutTests/fast/canvas/canvas-getImageData-invalid-result-buffer-crash.html >=================================================================== >--- LayoutTests/fast/canvas/canvas-getImageData-invalid-result-buffer-crash.html (revision 276819) >+++ LayoutTests/fast/canvas/canvas-getImageData-invalid-result-buffer-crash.html (working copy) >@@ -5,7 +5,7 @@ > function runTest() { > var canvas = document.getElementById("test"); > var ctx = canvas.getContext("2d"); >- ctx.getImageData(10000, 125, -381000000, -0.9); >+ ctx.getImageData(10000, 125, -381000000, -2); > } > </script> > </head> >Index: LayoutTests/fast/canvas/canvas-getImageData-invalid.html >=================================================================== >--- LayoutTests/fast/canvas/canvas-getImageData-invalid.html (revision 276819) >+++ LayoutTests/fast/canvas/canvas-getImageData-invalid.html (working copy) >@@ -9,18 +9,18 @@ description("Test the handling of invali > > ctx = document.createElement('canvas').getContext('2d'); > >-shouldThrow("ctx.getImageData(NaN, 10, 10, 10)", '"TypeError: The provided value is non-finite"'); >-shouldThrow("ctx.getImageData(10, NaN, 10, 10)", '"TypeError: The provided value is non-finite"'); >-shouldThrow("ctx.getImageData(10, 10, NaN, 10)", '"TypeError: The provided value is non-finite"'); >-shouldThrow("ctx.getImageData(10, 10, 10, NaN)", '"TypeError: The provided value is non-finite"'); >-shouldThrow("ctx.getImageData(Infinity, 10, 10, 10)", '"TypeError: The provided value is non-finite"'); >-shouldThrow("ctx.getImageData(10, Infinity, 10, 10)", '"TypeError: The provided value is non-finite"'); >-shouldThrow("ctx.getImageData(10, 10, Infinity, 10)", '"TypeError: The provided value is non-finite"'); >-shouldThrow("ctx.getImageData(10, 10, 10, Infinity)", '"TypeError: The provided value is non-finite"'); >-shouldThrow("ctx.getImageData(undefined, 10, 10, 10)", '"TypeError: The provided value is non-finite"'); >-shouldThrow("ctx.getImageData(10, undefined, 10, 10)", '"TypeError: The provided value is non-finite"'); >-shouldThrow("ctx.getImageData(10, 10, undefined, 10)", '"TypeError: The provided value is non-finite"'); >-shouldThrow("ctx.getImageData(10, 10, 10, undefined)", '"TypeError: The provided value is non-finite"'); >+shouldThrow("ctx.getImageData(NaN, 10, 10, 10)", '"TypeError: Value NaN is outside the range [-2147483648, 2147483647]"'); >+shouldThrow("ctx.getImageData(10, NaN, 10, 10)", '"TypeError: Value NaN is outside the range [-2147483648, 2147483647]"'); >+shouldThrow("ctx.getImageData(10, 10, NaN, 10)", '"TypeError: Value NaN is outside the range [-2147483648, 2147483647]"'); >+shouldThrow("ctx.getImageData(10, 10, 10, NaN)", '"TypeError: Value NaN is outside the range [-2147483648, 2147483647]"'); >+shouldThrow("ctx.getImageData(Infinity, 10, 10, 10)", '"TypeError: Value Infinity is outside the range [-2147483648, 2147483647]"'); >+shouldThrow("ctx.getImageData(10, Infinity, 10, 10)", '"TypeError: Value Infinity is outside the range [-2147483648, 2147483647]"'); >+shouldThrow("ctx.getImageData(10, 10, Infinity, 10)", '"TypeError: Value Infinity is outside the range [-2147483648, 2147483647]"'); >+shouldThrow("ctx.getImageData(10, 10, 10, Infinity)", '"TypeError: Value Infinity is outside the range [-2147483648, 2147483647]"'); >+shouldThrow("ctx.getImageData(undefined, 10, 10, 10)", '"TypeError: Value NaN is outside the range [-2147483648, 2147483647]"'); >+shouldThrow("ctx.getImageData(10, undefined, 10, 10)", '"TypeError: Value NaN is outside the range [-2147483648, 2147483647]"'); >+shouldThrow("ctx.getImageData(10, 10, undefined, 10)", '"TypeError: Value NaN is outside the range [-2147483648, 2147483647]"'); >+shouldThrow("ctx.getImageData(10, 10, 10, undefined)", '"TypeError: Value NaN is outside the range [-2147483648, 2147483647]"'); > shouldThrow("ctx.getImageData(10, 10, 0, 10)", '"IndexSizeError: The index is not in the allowed range."'); > shouldThrow("ctx.getImageData(10, 10, 10, 0)", '"IndexSizeError: The index is not in the allowed range."'); > </script> >Index: LayoutTests/fast/canvas/canvas-getImageData-large-crash-expected.txt >=================================================================== >--- LayoutTests/fast/canvas/canvas-getImageData-large-crash-expected.txt (revision 276819) >+++ LayoutTests/fast/canvas/canvas-getImageData-large-crash-expected.txt (working copy) >@@ -1 +1,2 @@ >+CONSOLE MESSAGE: TypeError: Value 4294967295 is outside the range [-2147483648, 2147483647] > PASSED (If this page did not crash.) >Index: LayoutTests/fast/canvas/canvas-getImageData-rounding-expected.txt >=================================================================== >--- LayoutTests/fast/canvas/canvas-getImageData-rounding-expected.txt (revision 276819) >+++ LayoutTests/fast/canvas/canvas-getImageData-rounding-expected.txt (working copy) >@@ -7,28 +7,28 @@ getImageData(0, 0, 20, 10) > PASS imageData.width is 20 > PASS imageData.height is 10 > getImageData(0.1, 0.2, 20, 10) >-PASS imageData.width is 21 >-PASS imageData.height is 11 >-getImageData(0.9, 0.8, 20, 10) >-PASS imageData.width is 21 >-PASS imageData.height is 11 >-getImageData(0, 0, 19.9, 9.9) > PASS imageData.width is 20 > PASS imageData.height is 10 >-getImageData(0, 0, 19.1, 9.1) >+getImageData(0.9, 0.8, 20, 10) > PASS imageData.width is 20 > PASS imageData.height is 10 >-getImageData(0.9, 0, 0.2, 10) >-PASS imageData.width is 2 >+getImageData(0, 0, 19.9, 9.9) >+PASS imageData.width is 19 >+PASS imageData.height is 9 >+getImageData(0, 0, 19.1, 9.1) >+PASS imageData.width is 19 >+PASS imageData.height is 9 >+getImageData(0.9, 0, 1.2, 10) >+PASS imageData.width is 1 > PASS imageData.height is 10 > getImageData(-1, -1, 20, 10) > PASS imageData.width is 20 > PASS imageData.height is 10 > getImageData(-1.1, 0, 20, 10) >-PASS imageData.width is 21 >+PASS imageData.width is 20 > PASS imageData.height is 10 > getImageData(-1.9, 0, 20, 10) >-PASS imageData.width is 21 >+PASS imageData.width is 20 > PASS imageData.height is 10 > PASS successfullyParsed is true > >Index: LayoutTests/fast/canvas/canvas-getImageData-rounding.html >=================================================================== >--- LayoutTests/fast/canvas/canvas-getImageData-rounding.html (revision 276819) >+++ LayoutTests/fast/canvas/canvas-getImageData-rounding.html (working copy) >@@ -11,8 +11,8 @@ ctx = document.createElement('canvas').g > > function dimensionsShouldBe(sx, sy, sw, sh, width, height) > { >- imageData = ctx.getImageData(sx, sy, sw, sh); > debug('getImageData(' + sx + ', ' + sy + ', ' + sw + ', ' + sh + ')'); >+ imageData = ctx.getImageData(sx, sy, sw, sh); > shouldBe('imageData.width', width + ''); > shouldBe('imageData.height', height + ''); > } >@@ -21,22 +21,22 @@ function dimensionsShouldBe(sx, sy, sw, > dimensionsShouldBe( 0, 0, 20, 10, 20, 10); > > // Source point is not an integer >-dimensionsShouldBe( .1, .2, 20, 10, 21, 11); >-dimensionsShouldBe( .9, .8, 20, 10, 21, 11); >+dimensionsShouldBe( .1, .2, 20, 10, 20, 10); >+dimensionsShouldBe( .9, .8, 20, 10, 20, 10); > > // Size is not an integer >-dimensionsShouldBe( 0, 0, 19.9, 9.9, 20, 10); >-dimensionsShouldBe( 0, 0, 19.1, 9.1, 20, 10); >+dimensionsShouldBe( 0, 0, 19.9, 9.9, 19, 9); >+dimensionsShouldBe( 0, 0, 19.1, 9.1, 19, 9); > > // Width straddles a pixel boundary >-dimensionsShouldBe( .9, 0, .2, 10, 2, 10); >+dimensionsShouldBe( .9, 0, 1.2, 10, 1, 10); > > // Basic integer negative values > dimensionsShouldBe( -1, -1, 20, 10, 20, 10); > > // Non-integer negative values >-dimensionsShouldBe(-1.1, 0, 20, 10, 21, 10); >-dimensionsShouldBe(-1.9, 0, 20, 10, 21, 10); >+dimensionsShouldBe(-1.1, 0, 20, 10, 20, 10); >+dimensionsShouldBe(-1.9, 0, 20, 10, 20, 10); > </script> > <script src="../../resources/js-test-post.js"></script> > </body> >Index: LayoutTests/fast/canvas/canvas-putImageData-expected.txt >=================================================================== >--- LayoutTests/fast/canvas/canvas-putImageData-expected.txt (revision 276819) >+++ LayoutTests/fast/canvas/canvas-putImageData-expected.txt (working copy) >@@ -145,24 +145,24 @@ PASS getPixel(9,9) is [0,128,0,255] > PASS getPixel(1,1) is [0,128,0,255] > PASS getPixel(9,9) is [0,128,0,255] > PASS context.putImageData({}, 0, 0) threw exception TypeError: Argument 1 ('imagedata') to CanvasRenderingContext2D.putImageData must be an instance of ImageData. >-PASS context.putImageData(buffer, NaN, 0, 0, 0, 0, 0) threw exception TypeError: The provided value is non-finite. >-PASS context.putImageData(buffer, 0, NaN, 0, 0, 0, 0) threw exception TypeError: The provided value is non-finite. >-PASS context.putImageData(buffer, 0, 0, NaN, 0, 0, 0) threw exception TypeError: The provided value is non-finite. >-PASS context.putImageData(buffer, 0, 0, 0, NaN, 0, 0) threw exception TypeError: The provided value is non-finite. >-PASS context.putImageData(buffer, 0, 0, 0, 0, NaN, 0) threw exception TypeError: The provided value is non-finite. >-PASS context.putImageData(buffer, 0, 0, 0, 0, 0, NaN) threw exception TypeError: The provided value is non-finite. >-PASS context.putImageData(buffer, Infinity, 0, 0, 0, 0, 0) threw exception TypeError: The provided value is non-finite. >-PASS context.putImageData(buffer, 0, Infinity, 0, 0, 0, 0) threw exception TypeError: The provided value is non-finite. >-PASS context.putImageData(buffer, 0, 0, Infinity, 0, 0, 0) threw exception TypeError: The provided value is non-finite. >-PASS context.putImageData(buffer, 0, 0, 0, Infinity, 0, 0) threw exception TypeError: The provided value is non-finite. >-PASS context.putImageData(buffer, 0, 0, 0, 0, Infinity, 0) threw exception TypeError: The provided value is non-finite. >-PASS context.putImageData(buffer, 0, 0, 0, 0, 0, Infinity) threw exception TypeError: The provided value is non-finite. >-PASS context.putImageData(buffer, undefined, 0, 0, 0, 0, 0) threw exception TypeError: The provided value is non-finite. >-PASS context.putImageData(buffer, 0, undefined, 0, 0, 0, 0) threw exception TypeError: The provided value is non-finite. >-PASS context.putImageData(buffer, 0, 0, undefined, 0, 0, 0) threw exception TypeError: The provided value is non-finite. >-PASS context.putImageData(buffer, 0, 0, 0, undefined, 0, 0) threw exception TypeError: The provided value is non-finite. >-PASS context.putImageData(buffer, 0, 0, 0, 0, undefined, 0) threw exception TypeError: The provided value is non-finite. >-PASS context.putImageData(buffer, 0, 0, 0, 0, 0, undefined) threw exception TypeError: The provided value is non-finite. >+PASS context.putImageData(buffer, NaN, 0, 0, 0, 0, 0) threw exception TypeError: Value NaN is outside the range [-2147483648, 2147483647]. >+PASS context.putImageData(buffer, 0, NaN, 0, 0, 0, 0) threw exception TypeError: Value NaN is outside the range [-2147483648, 2147483647]. >+PASS context.putImageData(buffer, 0, 0, NaN, 0, 0, 0) threw exception TypeError: Value NaN is outside the range [-2147483648, 2147483647]. >+PASS context.putImageData(buffer, 0, 0, 0, NaN, 0, 0) threw exception TypeError: Value NaN is outside the range [-2147483648, 2147483647]. >+PASS context.putImageData(buffer, 0, 0, 0, 0, NaN, 0) threw exception TypeError: Value NaN is outside the range [-2147483648, 2147483647]. >+PASS context.putImageData(buffer, 0, 0, 0, 0, 0, NaN) threw exception TypeError: Value NaN is outside the range [-2147483648, 2147483647]. >+PASS context.putImageData(buffer, Infinity, 0, 0, 0, 0, 0) threw exception TypeError: Value Infinity is outside the range [-2147483648, 2147483647]. >+PASS context.putImageData(buffer, 0, Infinity, 0, 0, 0, 0) threw exception TypeError: Value Infinity is outside the range [-2147483648, 2147483647]. >+PASS context.putImageData(buffer, 0, 0, Infinity, 0, 0, 0) threw exception TypeError: Value Infinity is outside the range [-2147483648, 2147483647]. >+PASS context.putImageData(buffer, 0, 0, 0, Infinity, 0, 0) threw exception TypeError: Value Infinity is outside the range [-2147483648, 2147483647]. >+PASS context.putImageData(buffer, 0, 0, 0, 0, Infinity, 0) threw exception TypeError: Value Infinity is outside the range [-2147483648, 2147483647]. >+PASS context.putImageData(buffer, 0, 0, 0, 0, 0, Infinity) threw exception TypeError: Value Infinity is outside the range [-2147483648, 2147483647]. >+PASS context.putImageData(buffer, undefined, 0, 0, 0, 0, 0) threw exception TypeError: Value NaN is outside the range [-2147483648, 2147483647]. >+PASS context.putImageData(buffer, 0, undefined, 0, 0, 0, 0) threw exception TypeError: Value NaN is outside the range [-2147483648, 2147483647]. >+PASS context.putImageData(buffer, 0, 0, undefined, 0, 0, 0) threw exception TypeError: Value NaN is outside the range [-2147483648, 2147483647]. >+PASS context.putImageData(buffer, 0, 0, 0, undefined, 0, 0) threw exception TypeError: Value NaN is outside the range [-2147483648, 2147483647]. >+PASS context.putImageData(buffer, 0, 0, 0, 0, undefined, 0) threw exception TypeError: Value NaN is outside the range [-2147483648, 2147483647]. >+PASS context.putImageData(buffer, 0, 0, 0, 0, 0, undefined) threw exception TypeError: Value NaN is outside the range [-2147483648, 2147483647]. > PASS successfullyParsed is true > > TEST COMPLETE >Index: LayoutTests/fast/canvas/canvas-putImageData.js >=================================================================== >--- LayoutTests/fast/canvas/canvas-putImageData.js (revision 276819) >+++ LayoutTests/fast/canvas/canvas-putImageData.js (working copy) >@@ -202,24 +202,24 @@ pixelShouldBe(9, 9, [0, 128,0,255]); > > > shouldThrowErrorName("context.putImageData({}, 0, 0)", "TypeError"); >-shouldThrow("context.putImageData(buffer, NaN, 0, 0, 0, 0, 0)", "'TypeError: The provided value is non-finite'"); >-shouldThrow("context.putImageData(buffer, 0, NaN, 0, 0, 0, 0)", "'TypeError: The provided value is non-finite'"); >-shouldThrow("context.putImageData(buffer, 0, 0, NaN, 0, 0, 0)", "'TypeError: The provided value is non-finite'"); >-shouldThrow("context.putImageData(buffer, 0, 0, 0, NaN, 0, 0)", "'TypeError: The provided value is non-finite'"); >-shouldThrow("context.putImageData(buffer, 0, 0, 0, 0, NaN, 0)", "'TypeError: The provided value is non-finite'"); >-shouldThrow("context.putImageData(buffer, 0, 0, 0, 0, 0, NaN)", "'TypeError: The provided value is non-finite'"); >-shouldThrow("context.putImageData(buffer, Infinity, 0, 0, 0, 0, 0)", "'TypeError: The provided value is non-finite'"); >-shouldThrow("context.putImageData(buffer, 0, Infinity, 0, 0, 0, 0)", "'TypeError: The provided value is non-finite'"); >-shouldThrow("context.putImageData(buffer, 0, 0, Infinity, 0, 0, 0)", "'TypeError: The provided value is non-finite'"); >-shouldThrow("context.putImageData(buffer, 0, 0, 0, Infinity, 0, 0)", "'TypeError: The provided value is non-finite'"); >-shouldThrow("context.putImageData(buffer, 0, 0, 0, 0, Infinity, 0)", "'TypeError: The provided value is non-finite'"); >-shouldThrow("context.putImageData(buffer, 0, 0, 0, 0, 0, Infinity)", "'TypeError: The provided value is non-finite'"); >-shouldThrow("context.putImageData(buffer, undefined, 0, 0, 0, 0, 0)", "'TypeError: The provided value is non-finite'"); >-shouldThrow("context.putImageData(buffer, 0, undefined, 0, 0, 0, 0)", "'TypeError: The provided value is non-finite'"); >-shouldThrow("context.putImageData(buffer, 0, 0, undefined, 0, 0, 0)", "'TypeError: The provided value is non-finite'"); >-shouldThrow("context.putImageData(buffer, 0, 0, 0, undefined, 0, 0)", "'TypeError: The provided value is non-finite'"); >-shouldThrow("context.putImageData(buffer, 0, 0, 0, 0, undefined, 0)", "'TypeError: The provided value is non-finite'"); >-shouldThrow("context.putImageData(buffer, 0, 0, 0, 0, 0, undefined)", "'TypeError: The provided value is non-finite'"); >+shouldThrow("context.putImageData(buffer, NaN, 0, 0, 0, 0, 0)", "'TypeError: Value NaN is outside the range [-2147483648, 2147483647]'"); >+shouldThrow("context.putImageData(buffer, 0, NaN, 0, 0, 0, 0)", "'TypeError: Value NaN is outside the range [-2147483648, 2147483647]'"); >+shouldThrow("context.putImageData(buffer, 0, 0, NaN, 0, 0, 0)", "'TypeError: Value NaN is outside the range [-2147483648, 2147483647]'"); >+shouldThrow("context.putImageData(buffer, 0, 0, 0, NaN, 0, 0)", "'TypeError: Value NaN is outside the range [-2147483648, 2147483647]'"); >+shouldThrow("context.putImageData(buffer, 0, 0, 0, 0, NaN, 0)", "'TypeError: Value NaN is outside the range [-2147483648, 2147483647]'"); >+shouldThrow("context.putImageData(buffer, 0, 0, 0, 0, 0, NaN)", "'TypeError: Value NaN is outside the range [-2147483648, 2147483647]'"); >+shouldThrow("context.putImageData(buffer, Infinity, 0, 0, 0, 0, 0)", "'TypeError: Value Infinity is outside the range [-2147483648, 2147483647]'"); >+shouldThrow("context.putImageData(buffer, 0, Infinity, 0, 0, 0, 0)", "'TypeError: Value Infinity is outside the range [-2147483648, 2147483647]'"); >+shouldThrow("context.putImageData(buffer, 0, 0, Infinity, 0, 0, 0)", "'TypeError: Value Infinity is outside the range [-2147483648, 2147483647]'"); >+shouldThrow("context.putImageData(buffer, 0, 0, 0, Infinity, 0, 0)", "'TypeError: Value Infinity is outside the range [-2147483648, 2147483647]'"); >+shouldThrow("context.putImageData(buffer, 0, 0, 0, 0, Infinity, 0)", "'TypeError: Value Infinity is outside the range [-2147483648, 2147483647]'"); >+shouldThrow("context.putImageData(buffer, 0, 0, 0, 0, 0, Infinity)", "'TypeError: Value Infinity is outside the range [-2147483648, 2147483647]'"); >+shouldThrow("context.putImageData(buffer, undefined, 0, 0, 0, 0, 0)", "'TypeError: Value NaN is outside the range [-2147483648, 2147483647]'"); >+shouldThrow("context.putImageData(buffer, 0, undefined, 0, 0, 0, 0)", "'TypeError: Value NaN is outside the range [-2147483648, 2147483647]'"); >+shouldThrow("context.putImageData(buffer, 0, 0, undefined, 0, 0, 0)", "'TypeError: Value NaN is outside the range [-2147483648, 2147483647]'"); >+shouldThrow("context.putImageData(buffer, 0, 0, 0, undefined, 0, 0)", "'TypeError: Value NaN is outside the range [-2147483648, 2147483647]'"); >+shouldThrow("context.putImageData(buffer, 0, 0, 0, 0, undefined, 0)", "'TypeError: Value NaN is outside the range [-2147483648, 2147483647]'"); >+shouldThrow("context.putImageData(buffer, 0, 0, 0, 0, 0, undefined)", "'TypeError: Value NaN is outside the range [-2147483648, 2147483647]'"); > > // Ensure we don't mess up bounds clipping checks > var rectcanvas = document.createElement("canvas"); >Index: LayoutTests/fast/canvas/resources/canvas-2d-imageData-create-nonfinite.js >=================================================================== >--- LayoutTests/fast/canvas/resources/canvas-2d-imageData-create-nonfinite.js (revision 276819) >+++ LayoutTests/fast/canvas/resources/canvas-2d-imageData-create-nonfinite.js (working copy) >@@ -3,10 +3,10 @@ description("Test the argument bounds of > var canvas = document.getElementById('canvas'); > var ctx = canvas.getContext('2d'); > >-shouldThrow("ctx.createImageData(Infinity, Infinity)", '"TypeError: The provided value is non-finite"'); >-shouldThrow("ctx.createImageData(Infinity, 10)", '"TypeError: The provided value is non-finite"'); >-shouldThrow("ctx.createImageData(-Infinity, 10)", '"TypeError: The provided value is non-finite"'); >-shouldThrow("ctx.createImageData(10, Infinity)", '"TypeError: The provided value is non-finite"'); >-shouldThrow("ctx.createImageData(10, -Infinity)", '"TypeError: The provided value is non-finite"'); >-shouldThrow("ctx.createImageData(NaN, 10)", '"TypeError: The provided value is non-finite"'); >-shouldThrow("ctx.createImageData(10, NaN)", '"TypeError: The provided value is non-finite"'); >+shouldThrow("ctx.createImageData(Infinity, Infinity)", '"TypeError: Value Infinity is outside the range [-2147483648, 2147483647]"'); >+shouldThrow("ctx.createImageData(Infinity, 10)", '"TypeError: Value Infinity is outside the range [-2147483648, 2147483647]"'); >+shouldThrow("ctx.createImageData(-Infinity, 10)", '"TypeError: Value -Infinity is outside the range [-2147483648, 2147483647]"'); >+shouldThrow("ctx.createImageData(10, Infinity)", '"TypeError: Value Infinity is outside the range [-2147483648, 2147483647]"'); >+shouldThrow("ctx.createImageData(10, -Infinity)", '"TypeError: Value -Infinity is outside the range [-2147483648, 2147483647]"'); >+shouldThrow("ctx.createImageData(NaN, 10)", '"TypeError: Value NaN is outside the range [-2147483648, 2147483647]"'); >+shouldThrow("ctx.createImageData(10, NaN)", '"TypeError: Value NaN is outside the range [-2147483648, 2147483647]"'); >Index: LayoutTests/imported/w3c/ChangeLog >=================================================================== >--- LayoutTests/imported/w3c/ChangeLog (revision 276873) >+++ LayoutTests/imported/w3c/ChangeLog (working copy) >@@ -1,3 +1,22 @@ >+2021-05-01 Sam Weinig <weinig@apple.com> >+ >+ Update operations in CanvasImageData.idl to use long rather than float as per spec >+ https://bugs.webkit.org/show_bug.cgi?id=225263 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ * canvas/2d.imageData.create2.tiny-expected.txt: >+ * canvas/2d.imageData.get.tiny-expected.txt: >+ Update results, which now don't pass, to match the spec behavior. >+ >+ * web-platform-tests/html/canvas/element/pixel-manipulation/2d.imageData.create2.double-expected.txt: >+ * web-platform-tests/html/canvas/element/pixel-manipulation/2d.imageData.create2.zero-expected.txt: >+ * web-platform-tests/html/canvas/element/pixel-manipulation/2d.imageData.get.double-expected.txt: >+ * web-platform-tests/html/canvas/element/pixel-manipulation/2d.imageData.get.large.crash-expected.txt: >+ * web-platform-tests/html/canvas/element/pixel-manipulation/2d.imageData.get.rounding-expected.txt: >+ * web-platform-tests/html/canvas/element/pixel-manipulation/2d.imageData.get.zero-expected.txt: >+ Update results, which now pass! >+ > 2021-04-30 Oriol Brufau <obrufau@igalia.com> > > [css-logical] Fix logical shorthands with var() >Index: LayoutTests/imported/w3c/canvas/2d.imageData.create2.tiny-expected.txt >=================================================================== >--- LayoutTests/imported/w3c/canvas/2d.imageData.create2.tiny-expected.txt (revision 276873) >+++ LayoutTests/imported/w3c/canvas/2d.imageData.create2.tiny-expected.txt (working copy) >@@ -2,4 +2,4 @@ > createImageData(sw, sh) works for sizes smaller than one pixel > Spec references: 2d.imageData.create2.size 2d.imageData.one > Actual output: >-Passed >+Aborted with exception: The index is not in the allowed range. >Index: LayoutTests/imported/w3c/canvas/2d.imageData.get.tiny-expected.txt >=================================================================== >--- LayoutTests/imported/w3c/canvas/2d.imageData.get.tiny-expected.txt (revision 276873) >+++ LayoutTests/imported/w3c/canvas/2d.imageData.get.tiny-expected.txt (working copy) >@@ -2,4 +2,4 @@ > getImageData() works for sizes smaller than one pixel > Spec references: 2d.imageData.one > Actual output: >-Passed >+Aborted with exception: The index is not in the allowed range. >Index: LayoutTests/imported/w3c/web-platform-tests/html/canvas/element/pixel-manipulation/2d.imageData.create2.double-expected.txt >=================================================================== >--- LayoutTests/imported/w3c/web-platform-tests/html/canvas/element/pixel-manipulation/2d.imageData.create2.double-expected.txt (revision 276873) >+++ LayoutTests/imported/w3c/web-platform-tests/html/canvas/element/pixel-manipulation/2d.imageData.create2.double-expected.txt (working copy) >@@ -2,5 +2,5 @@ > createImageData(w, h) double is converted to long > Actual output: > >-FAIL createImageData(w, h) double is converted to long assert_equals: imgdata1.width === 10 (got 11[number], expected 10[number]) expected 10 but got 11 >+PASS createImageData(w, h) double is converted to long > >Index: LayoutTests/imported/w3c/web-platform-tests/html/canvas/element/pixel-manipulation/2d.imageData.create2.zero-expected.txt >=================================================================== >--- LayoutTests/imported/w3c/web-platform-tests/html/canvas/element/pixel-manipulation/2d.imageData.create2.zero-expected.txt (revision 276873) >+++ LayoutTests/imported/w3c/web-platform-tests/html/canvas/element/pixel-manipulation/2d.imageData.create2.zero-expected.txt (working copy) >@@ -2,5 +2,5 @@ > createImageData(sw, sh) throws INDEX_SIZE_ERR if size is zero > Actual output: > >-FAIL createImageData(sw, sh) throws INDEX_SIZE_ERR if size is zero assert_throws_dom: function "function () { ctx.createImageData(0.99, 10); }" did not throw >+PASS createImageData(sw, sh) throws INDEX_SIZE_ERR if size is zero > >Index: LayoutTests/imported/w3c/web-platform-tests/html/canvas/element/pixel-manipulation/2d.imageData.get.double-expected.txt >=================================================================== >--- LayoutTests/imported/w3c/web-platform-tests/html/canvas/element/pixel-manipulation/2d.imageData.get.double-expected.txt (revision 276873) >+++ LayoutTests/imported/w3c/web-platform-tests/html/canvas/element/pixel-manipulation/2d.imageData.get.double-expected.txt (working copy) >@@ -2,5 +2,5 @@ > createImageData(w, h) double is converted to long > Actual output: > >-FAIL createImageData(w, h) double is converted to long assert_equals: imgdata1.width === 10 (got 11[number], expected 10[number]) expected 10 but got 11 >+PASS createImageData(w, h) double is converted to long > >Index: LayoutTests/imported/w3c/web-platform-tests/html/canvas/element/pixel-manipulation/2d.imageData.get.large.crash-expected.txt >=================================================================== >--- LayoutTests/imported/w3c/web-platform-tests/html/canvas/element/pixel-manipulation/2d.imageData.get.large.crash-expected.txt (revision 276873) >+++ LayoutTests/imported/w3c/web-platform-tests/html/canvas/element/pixel-manipulation/2d.imageData.get.large.crash-expected.txt (working copy) >@@ -2,5 +2,5 @@ > Test that canvas crash when image data cannot be allocated. > Actual output: > >-FAIL Test that canvas crash when image data cannot be allocated. assert_throws_js: function "function () { ctx.getImageData(10, 0xffffffff, 2147483647, 10); }" did not throw >+PASS Test that canvas crash when image data cannot be allocated. > >Index: LayoutTests/imported/w3c/web-platform-tests/html/canvas/element/pixel-manipulation/2d.imageData.get.rounding-expected.txt >=================================================================== >--- LayoutTests/imported/w3c/web-platform-tests/html/canvas/element/pixel-manipulation/2d.imageData.get.rounding-expected.txt (revision 276873) >+++ LayoutTests/imported/w3c/web-platform-tests/html/canvas/element/pixel-manipulation/2d.imageData.get.rounding-expected.txt (working copy) >@@ -2,5 +2,5 @@ > Test the handling of non-integer source coordinates in getImageData(). > Actual output: > >-FAIL Test the handling of non-integer source coordinates in getImageData(). assert_true: imageData.width == width expected true got false >+PASS Test the handling of non-integer source coordinates in getImageData(). > >Index: LayoutTests/imported/w3c/web-platform-tests/html/canvas/element/pixel-manipulation/2d.imageData.get.zero-expected.txt >=================================================================== >--- LayoutTests/imported/w3c/web-platform-tests/html/canvas/element/pixel-manipulation/2d.imageData.get.zero-expected.txt (revision 276873) >+++ LayoutTests/imported/w3c/web-platform-tests/html/canvas/element/pixel-manipulation/2d.imageData.get.zero-expected.txt (working copy) >@@ -2,5 +2,5 @@ > getImageData() throws INDEX_SIZE_ERR if size is zero > Actual output: > >-FAIL getImageData() throws INDEX_SIZE_ERR if size is zero assert_throws_dom: function "function () { ctx.getImageData(1, 1, 0.1, 10); }" did not throw >+PASS getImageData() throws INDEX_SIZE_ERR if size is zero >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 225263
:
427480
| 427498