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•3 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•3 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•3 years ago
|
Updated•3 years ago
|
Assignee | ||
Updated•3 years ago
|
Pushed by amccreight@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/abd24a07274d Use the lazy pref getter workaround for SHOW_OTHER_BOOKMARKS. r=Gijs
Assignee | ||
Comment 4•3 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•3 years ago
|
||
bugherder |
Assignee | ||
Comment 6•3 years ago
|
||
This can also touch the doc, so we don't want to run it if the
doc has been unlinked.
Assignee | ||
Updated•3 years ago
|
Pushed by amccreight@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/335755f56e63 Don't run maybeShowOtherBookmarksFolder if doc has gone away. r=kmag
Comment 8•3 years ago
|
||
bugherder |
Description
•