Closed Bug 1555954 Opened 5 years ago Closed 5 years ago

Serialize content crash annotations in binary format when sending them to the main process

Categories

(Toolkit :: Crash Reporting, task)

task
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla69
Tracking Status
firefox69 --- fixed

People

(Reporter: gsvelto, Assigned: gsvelto)

References

Details

Attachments

(1 file)

Exception-time crash annotations are generated in the PrepareChildExceptionTimeAnnotations() functions and sent to the main process via a pipe. Before bug 1407693 they were written to a file instead so the format they're serialized to is the same INI-style format used for the .extra file.

This is inconvenient as it requires turning the annotations into strings and escaping them. However since we're in a crashed context only the MozCrashReason annotation is escaped, the others aren't leading to data loss in case they contain null or newline characters.

Additionally we need to parse and validate the strings in the main process before serializing them back into the .extra file.

Since the serialized annotations are not seen by any other code save for PrepareChildExceptionTimeAnnotations() and ReadAndValidateExceptionTimeAnnotations() it would be simpler to serialize them and read them back in a binary format such as <annotation>/<size>/<data>. The data would also not require escaping then.

Assignee: nobody → gsvelto
Status: NEW → ASSIGNED
Type: defect → task
Pushed by gsvelto@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/f9c7f4ab3500 Serialize content processes' exception-time annotations in binary format when sending them to the main process r=froydnj
Status: ASSIGNED → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla69
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: