Open Bug 1915991 Opened 1 year ago Updated 1 year ago

Consider making nsCycleCollector_init() infallible

Categories

(Core :: Cycle Collector, enhancement)

enhancement

Tracking

()

People

(Reporter: mccr8, Unassigned)

Details

nsCycleCollector_init() can fail if we can't create TLS. I have no idea how that could happen, but the resulting failures would be so odd we're probably better off crashing immediately. ThreadLocal has a infallibleInit method we could use.

I guess we do crash immediately on the main thread if it fails, in _startup(), so this only affects worker threads. That's probably better equipped to deal with weird failures so maybe it is fine as is.

Wait, we don't crash because we return. Never mind.

You need to log in before you can comment on or make changes to this bug.