summaryrefslogtreecommitdiff
path: root/Userland/Libraries/LibWeb/CSS/CSSImportRule.cpp
diff options
context:
space:
mode:
authorAndreas Kling <kling@serenityos.org>2022-08-07 13:14:54 +0200
committerAndreas Kling <kling@serenityos.org>2022-09-06 00:27:09 +0200
commit5d60212076f05fd85607e05e1496ad009dcf501b (patch)
treef14e5cf5e08624aad9ea01ea99d0cc618ff1ac39 /Userland/Libraries/LibWeb/CSS/CSSImportRule.cpp
parent0fe923e35580ce1745f47c0d812ce7689ae84063 (diff)
downloadserenity-5d60212076f05fd85607e05e1496ad009dcf501b.zip
LibWeb: Make StyleSheet and CSSStyleSheet GC-allocated
Diffstat (limited to 'Userland/Libraries/LibWeb/CSS/CSSImportRule.cpp')
-rw-r--r--Userland/Libraries/LibWeb/CSS/CSSImportRule.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/Userland/Libraries/LibWeb/CSS/CSSImportRule.cpp b/Userland/Libraries/LibWeb/CSS/CSSImportRule.cpp
index 932d8120c7..61ea65e7bc 100644
--- a/Userland/Libraries/LibWeb/CSS/CSSImportRule.cpp
+++ b/Userland/Libraries/LibWeb/CSS/CSSImportRule.cpp
@@ -73,13 +73,13 @@ void CSSImportRule::resource_did_load()
dbgln_if(CSS_LOADER_DEBUG, "CSSImportRule: Resource did load, has encoded data. URL: {}", resource()->url());
}
- auto sheet = parse_css_stylesheet(CSS::Parser::ParsingContext(*m_document, resource()->url()), resource()->encoded_data());
+ auto* sheet = parse_css_stylesheet(CSS::Parser::ParsingContext(*m_document, resource()->url()), resource()->encoded_data());
if (!sheet) {
dbgln_if(CSS_LOADER_DEBUG, "CSSImportRule: Failed to parse stylesheet: {}", resource()->url());
return;
}
- m_style_sheet = move(sheet);
+ m_style_sheet = JS::make_handle(sheet);
m_document->style_computer().invalidate_rule_cache();
m_document->invalidate_style();