mirror of
https://github.com/servo/servo.git
synced 2025-09-30 08:39:16 +01:00
script: Let canvas serialization to image fail gracefully (#37184)
Instead of panicking when serialization of canvas to image data (whether through `toBlob()` or via `toDataURL()`), properly handle failed serialization. This is an implementation of the appropriate error handling from the specification text. Testing: This change includes a new Serov-specific test, because it is impossible to know what the canvas size limits are of all browsers. Fixes: #36840. Signed-off-by: Martin Robinson <mrobinson@igalia.com>
This commit is contained in:
parent
36e4886da1
commit
559ba4b3ee
3 changed files with 100 additions and 40 deletions
7
tests/wpt/mozilla/meta/MANIFEST.json
vendored
7
tests/wpt/mozilla/meta/MANIFEST.json
vendored
|
@ -12850,6 +12850,13 @@
|
|||
]
|
||||
]
|
||||
},
|
||||
"canvas-oversize-serialization.html": [
|
||||
"3330ee2b8c4e33a18a3e17151fd7c398c9a5d024",
|
||||
[
|
||||
null,
|
||||
{}
|
||||
]
|
||||
],
|
||||
"canvas.initial.reset.2dstate.html": [
|
||||
"e276ed09ffcf16eff16b784c622b93665c4109ee",
|
||||
[
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue