1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 20:07:35 +00:00

LibWeb: Make CSSStyleSheet::m_owner_css_rule a WeakPtr

It's not safe for this to be a raw pointer, as the imported style sheet
can outlive the rule.
This commit is contained in:
Andreas Kling 2021-12-05 15:30:40 +01:00
parent f47c658275
commit e8b85b13e2
2 changed files with 4 additions and 3 deletions

View file

@ -52,8 +52,7 @@ private:
NonnullRefPtr<CSSRuleList> m_rules;
// FIXME: Use WeakPtr.
CSSRule* m_owner_css_rule { nullptr };
WeakPtr<CSSRule> m_owner_css_rule;
};
}