Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

LibWeb: Don't crash when upgrading custom element with a bad constructor #3235

Merged
merged 1 commit into from
Jan 13, 2025

Conversation

tcl3
Copy link
Member

@tcl3 tcl3 commented Jan 12, 2025

Previously, a crash would occur when attempting to throw an error in this case because the method used to create the exception tried to get the current realm from the execution context stack, which is empty. The realm is now passed explicitly when constructing the error, avoiding the crash.

Fixes: http://wpt.live/custom-elements/parser/parser-fallsback-to-unknown-element.html

Previously, a crash would occur when attempting to throw an error in
this case because the method used to create the exception tried to get
the current realm from the execution context stack, which is empty. The
realm is now passed explicitly when constructing the error, avoiding
the crash.
@Lubrsi Lubrsi merged commit 619df0b into LadybirdBrowser:master Jan 13, 2025
8 checks passed
@tcl3 tcl3 deleted the libweb_custom_element_errors branch January 13, 2025 11:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants