Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
AX: Voice Control cannot access any web content
https://bugs.webkit.org/show_bug.cgi?id=259951 rdar://113280724 Reviewed by Chris Fleizach. This is a regression from https://bugs.webkit.org/show_bug.cgi?id=256238, which changed `-[WKAccessibilityWebPageObjectMac accessibilityAttributeNames]` to return `m_attributeNames` via `.autorelease()` rather than `.get()`. Returning via autorelease causes the backing NSArray to be released after the next iteration of the runloop, meaning subsequent requests to `accessibilityAttributeNames` return nil. Voice Control relies on this output being correct to function. With this patch, both `m_attributeNames` and `m_parameterizedAttributeNames` are returned via `RetainPtr::get()`, preventing their early deletion. This matches the getters for other `RetainPtr<NSArray> m_foo` types throughout WebKit. * Source/WebKit/WebProcess/WebPage/mac/WKAccessibilityWebPageObjectMac.mm: (-[WKAccessibilityWebPageObject ALLOW_DEPRECATED_IMPLEMENTATIONS_END]): Canonical link: https://commits.webkit.org/266714@main
- Loading branch information