Closed Bug 1118164 Opened 10 years ago Closed 10 years ago

Tracelogging: Don't fail if there is no logger

Categories

(Core :: JavaScript Engine, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla37

People

(Reporter: h4writer, Assigned: h4writer)

References

Details

Attachments

(1 file)

No description provided.
Attached patch PatchSplinter Review
"logger" can be a nullptr upon fail.
Assignee: nobody → hv1989
Attachment #8544450 - Flags: review?(benj)
Comment on attachment 8544450 [details] [diff] [review] Patch Review of attachment 8544450 [details] [diff] [review]: ----------------------------------------------------------------- I'm okay with this, but in the first place, why would we even create the TLEvent if there's no logger?
Attachment #8544450 - Flags: review?(benj) → review+
Blocks: 1065722
(In reply to Benjamin Bouvier [:bbouvier] from comment #2) > I'm okay with this, but in the first place, why would we even create the > TLEvent if there's no logger? The code is: > js::TraceLoggerEvent event(logger, TraceLogger_AnnotateScripts, options); > js::AutoTraceLog scriptLogger(logger, event); To make it easier to read the code we only test for a logger inside AutoTraceLog and TraceLogStartEvent etc. So the event is made unconditionally.
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla37
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: