LibWeb/HTML: Avoid crash for extreme bitmap sizes in OffscreenCanvas

This commit is contained in:
Shannon Booth 2025-09-20 18:36:10 +02:00 committed by Sam Atkins
commit e3b5507113
Notes: github-actions[bot] 2025-09-22 11:38:58 +00:00
4 changed files with 51 additions and 5 deletions

View file

@ -80,7 +80,7 @@ private:
JS::ThrowCompletionOr<HasOrCreatedContext> create_2d_context(JS::Value options);
void reset_context_to_default_state();
void set_new_bitmap_size(Gfx::IntSize new_size);
WebIDL::ExceptionOr<void> set_new_bitmap_size(Gfx::IntSize new_size);
Variant<GC::Ref<HTML::OffscreenCanvasRenderingContext2D>, GC::Ref<WebGL::WebGLRenderingContext>, GC::Ref<WebGL::WebGL2RenderingContext>, Empty> m_context;