Bug 269331 - Element::userAgentShadowRoot() shouldn't return a RefPtr
Summary: Element::userAgentShadowRoot() shouldn't return a RefPtr
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: DOM (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Chris Dumez
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2024-02-13 16:16 PST by Chris Dumez
Modified: 2024-02-13 19:44 PST (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Chris Dumez 2024-02-13 16:16:30 PST
Element::userAgentShadowRoot() shouldn't return a RefPtr. It causes unnecessary ref-counting churn for caller that don't need it. Have it return a raw pointer instead and add a `protectedUserAgentShadowRoot()` getter for the callers that actually want a RefPtr.
Comment 1 Chris Dumez 2024-02-13 16:21:08 PST
Pull request: https://github.com/WebKit/WebKit/pull/24382
Comment 2 EWS 2024-02-13 19:43:40 PST
Committed 274602@main (9951fe460428): <https://commits.webkit.org/274602@main>

Reviewed commits have been landed. Closing PR #24382 and removing active labels.
Comment 3 Radar WebKit Bug Importer 2024-02-13 19:44:24 PST
<rdar://problem/122927497>