[webkit-changes] [WebKit/WebKit] cc6c9a: Handle bitmap allocation failure in OffscreenCanva...

mattwoodrow noreply at github.com
Mon Oct 31 18:19:34 PDT 2022


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: cc6c9a484504dc6f5500c20a82e3e7e0ba61daf5
      https://github.com/WebKit/WebKit/commit/cc6c9a484504dc6f5500c20a82e3e7e0ba61daf5
  Author: Matt Woodrow <mattwoodrow at apple.com>
  Date:   2022-10-31 (Mon, 31 Oct 2022)

  Changed paths:
    A LayoutTests/fast/canvas/offscreen-giant-transfer-to-imagebitmap-expected.txt
    A LayoutTests/fast/canvas/offscreen-giant-transfer-to-imagebitmap.html
    A LayoutTests/platform/mac-wk1/fast/canvas/offscreen-giant-transfer-to-imagebitmap-expected.txt
    A LayoutTests/platform/win/fast/canvas/offscreen-giant-transfer-to-imagebitmap-expected.txt
    M Source/WebCore/html/OffscreenCanvas.cpp

  Log Message:
  -----------
  Handle bitmap allocation failure in OffscreenCanvas::transferToImageBitmap.
https://bugs.webkit.org/show_bug.cgi?id=247247
<rdar://101591380>

Reviewed by Chris Lord.

transferToImageBitmap can be called when we were unable to allocate a bitmap, we should handle this the same way as HTMLCanvasElement::toBlob and return null.

* LayoutTests/fast/canvas/offscreen-giant-transfer-to-imagebitmap-expected.txt: Added.
* LayoutTests/fast/canvas/offscreen-giant-transfer-to-imagebitmap.html: Added.
* LayoutTests/platform/mac-wk1/fast/canvas/offscreen-giant-transfer-to-imagebitmap-expected.txt: Added.
* LayoutTests/platform/win/fast/canvas/offscreen-giant-transfer-to-imagebitmap-expected.txt: Added.
* Source/WebCore/html/OffscreenCanvas.cpp:
(WebCore::OffscreenCanvas::transferToImageBitmap):

Canonical link: https://commits.webkit.org/256178@main




More information about the webkit-changes mailing list