Closed Bug 1697270 Opened 1 month ago Closed 1 month ago

Deprecate GeckoResult.ALLOW and GeckoResult.DENY

Categories

(GeckoView :: General, defect)

Unspecified
All
defect

Tracking

(firefox88 fixed)

RESOLVED FIXED
88 Branch
Tracking Status
firefox88 --- fixed

People

(Reporter: agi, Assigned: agi)

References

(Blocks 1 open bug)

Details

Attachments

(1 file)

They are big footguns because it's very easy to access them on a non-Looper thread causing crashes like https://crash-stats.mozilla.org/report/index/2cd0b068-2f67-48b2-b2db-4b08c0210309

When built as static members, we observe GeckoResult.allow and deny getting
built on threads that don't have a Looper (or maybe built before the looper is
initialized?).

This change makes it so that the ALLOW and DENY instances are built when called
and kept thread local, to conform with the caller's expectations that any
callback is executed on the same thread.

Assignee: nobody → agi
Status: NEW → ASSIGNED
Attachment #9207911 - Attachment description: Bug 1697270 - Provide ThreadLocal GeckoResult.allow() and .deny() → Bug 1697270 - Provide GeckoResult.allow() and .deny()
Pushed by asferro@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/d487e57a3d70
Provide GeckoResult.allow() and .deny() r=owlish,droeh
Status: ASSIGNED → RESOLVED
Closed: 1 month ago
Resolution: --- → FIXED
Target Milestone: --- → 88 Branch
You need to log in before you can comment on or make changes to this bug.