Open Bug 1456902 Opened 6 years ago Updated 2 years ago

Crash more eagerly on parse errors when deserializing preferences, and use CrashReporter::RegisterAppMemory to supply context

Categories

(Core :: Preferences: Backend, enhancement, P3)

enhancement

Tracking

()

People

(Reporter: jld, Unassigned)

References

Details

See bug 1455828 comment #4 and 5: pref deserialization does things like converting a bad type letter into PrefType::None, with only an NS_ERROR, even when that will always cause a MOZ_CRASH later.  If we're going to crash we should crash early and try to preserve context.

On that topic, we can use CrashReporter::RegisterAppMemory to include the malformed pref data in the minidump.  (That may need some thought about the privacy implications, although we already include the stack and environment variables, which can have a significant amount of sensitive information.)
One possibility is to only include a fragment of the pref data, such as the last 64 bytes. That should give almost the same amount utility as the full data.
This wound up not being needed to diagnose bug 1455828.  It still might be useful, so I'll leave it open.
Assignee: jld → nobody
No longer blocks: 1455828, 1457319
Priority: P2 → P3
See Also: → 1455828
Severity: normal → S3
You need to log in before you can comment on or make changes to this bug.