aboutsummaryrefslogtreecommitdiffstats
path: root/components/servo/webview.rs
diff options
context:
space:
mode:
authorAndrei Volykhin <andrei.volykhin@gmail.com>2025-04-17 09:41:23 +0300
committerGitHub <noreply@github.com>2025-04-17 06:41:23 +0000
commit95ee5708fa432a2903d39c40df5e38ff435f30c1 (patch)
tree0b15572f1c968fce70304cc2bd16e253cbb8bffb /components/servo/webview.rs
parentd7e560c9c048a8ea3b9d5b4e4a8d3905d743c9d2 (diff)
downloadservo-95ee5708fa432a2903d39c40df5e38ff435f30c1.tar.gz
servo-95ee5708fa432a2903d39c40df5e38ff435f30c1.zip
imagedata: Fix overflow panic for too large ImageData (#36569)
In Servo debug build there are runtime crash due to "attempt to multiply with overflow" panic in case of creation too large ImageData (new ImageData(1<<31, 1<<31)) Use checked integer multiplication to catch occurred overflow and throwing JS error (RangeError OR IndexSizeError). -- - [x] ./mach build -d does not report any errors - [x] ./mach test-tidy does not report any errors - [x] There are tests for these changes tests/wpt/tests/html/canvas/element/pixel-manipulation/2d.imageData.object.ctor.basics.html Signed-off-by: Andrei Volykhin <andrei.volykhin@gmail.com>
Diffstat (limited to 'components/servo/webview.rs')
0 files changed, 0 insertions, 0 deletions