Closed
Bug 1342067
Opened 7 years ago
Closed 7 years ago
Annotate the name of the preference accessed too early in the pre-END_INIT_PREFS phase preference access crash message
Categories
(Core :: Preferences: Backend, defect)
Core
Preferences: Backend
Tracking
()
RESOLVED
FIXED
mozilla54
Tracking | Status | |
---|---|---|
firefox54 | --- | fixed |
People
(Reporter: ehsan.akhgari, Assigned: ehsan.akhgari)
References
Details
Attachments
(1 file)
I keep hitting this assertion when I run tests these days, and it's impossible to tell which pref caused it. Let's add the name of the preference to the message.
Assignee | ||
Comment 1•7 years ago
|
||
Attachment #8840447 -
Flags: review?(blassey.bugs)
Comment 2•7 years ago
|
||
Comment on attachment 8840447 [details] [diff] [review] Annotate the name of the preference accessed too early in the pre-END_INIT_PREFS phase preference access crash message Review of attachment 8840447 [details] [diff] [review]: ----------------------------------------------------------------- ::: modules/libpref/prefapi.cpp @@ +775,5 @@ > * and get review from a DOM peer > */ > +#ifdef DEBUG > + if (XRE_IsContentProcess() && gPhase <= END_INIT_PREFS && !inInitArray(key)) { > + MOZ_CRASH_UNSAFE_PRINTF("accessing non-init pref %s before the rest of the prefs are sent", how did I not know about this macro!?!?!
Attachment #8840447 -
Flags: review?(blassey.bugs) → review+
Assignee | ||
Comment 3•7 years ago
|
||
(In reply to Brad Lassey [:blassey] (use needinfo?) from comment #2) > Comment on attachment 8840447 [details] [diff] [review] > Annotate the name of the preference accessed too early in the > pre-END_INIT_PREFS phase preference access crash message > > Review of attachment 8840447 [details] [diff] [review]: > ----------------------------------------------------------------- > > ::: modules/libpref/prefapi.cpp > @@ +775,5 @@ > > * and get review from a DOM peer > > */ > > +#ifdef DEBUG > > + if (XRE_IsContentProcess() && gPhase <= END_INIT_PREFS && !inInitArray(key)) { > > + MOZ_CRASH_UNSAFE_PRINTF("accessing non-init pref %s before the rest of the prefs are sent", > > how did I not know about this macro!?!?! I only learned about it as I was rolling my own version. ;-)
Pushed by eakhgari@mozilla.com: https://hg.mozilla.org/integration/mozilla-inbound/rev/ef1063db138c Annotate the name of the preference accessed too early in the pre-END_INIT_PREFS phase preference access crash message; r=blassey
Comment 5•7 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/ef1063db138c
Status: NEW → RESOLVED
Closed: 7 years ago
status-firefox54:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla54
You need to log in
before you can comment on or make changes to this bug.
Description
•