Use the lazy pref getter workaround for SHOW_OTHER_BOOKMARKS.
Categories
(Core :: XPCOM, defect, P1)
Tracking
()
| Tracking | Status | |
|---|---|---|
| firefox89 | --- | fixed |
People
(Reporter: mccr8, Assigned: mccr8)
References
Details
Attachments
(2 files, 1 obsolete file)
If we're going to need this work around, I think it makes sense to make it easier to use. I've written a new XPCOMUtils method defineWeakLazyPreferenceGetter that takes an extra argument. It creates a weak reference to this object, and only calls the callback if the weak reference referent is still around. It also passes the object into the callback. I suppose technically that isn't necessary, but not doing it would more bizarre looking.
I've also fixed the SHOW_OTHER_BOOKMARKS getter which looks like it is the only lazy pref callback actually being run in browser_toolbar_other_bookmarks.js, so hopefully this will tamp down bug 1652531 again.
| Assignee | ||
Comment 1•5 years ago
|
||
This adds a new helper method that deals with the weak ref stuff itself,
and updates the other place I fixed to use it.
aWeakObject is a later argument so that the ES lint setter
checking stuff still works.
| Assignee | ||
Comment 2•5 years ago
|
||
This lazy pref getter callback fires a number of times while running
browser_toolbar_other_bookmarks.js, which is experiencing a number
of intermittent failures due to the XPCWJS weak reference CC issue
(bug 1652531) so hopefully this will fix that.
Updated•5 years ago
|
Updated•5 years ago
|
| Assignee | ||
Updated•5 years ago
|
| Assignee | ||
Comment 4•5 years ago
|
||
kmag pointed out an issue with my patch I'll have to follow up on. Feel free to back it out.
Comment 5•5 years ago
|
||
| bugherder | ||
| Assignee | ||
Comment 6•5 years ago
|
||
This can also touch the doc, so we don't want to run it if the
doc has been unlinked.
| Assignee | ||
Updated•5 years ago
|
Comment 8•5 years ago
|
||
| bugherder | ||
Description
•