Closed Bug 579249 Opened 11 years ago Closed 10 years ago

xpcshell should handle EINTR from fgets (makes attaching in gdb possible)

Categories

(Core :: XPConnect, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla7

People

(Reporter: joe, Assigned: joe)

References

Details

(Whiteboard: [inbound])

Attachments

(1 file, 1 obsolete file)

Attached patch handle EINTR (obsolete) — Splinter Review
Right now, xpcshell exits gracefully whenever it gets a NULL return value from fgets(). However, there are valid NULL return values possible from fgets(), like when it's interrupted by a system call. 

This patch makes xpcshell not exit in those cases, which makes attaching to xpcshell in GDB possible.
Attachment #457754 - Flags: review?
Attached patch handle EINTR v2Splinter Review
testing ftw
Assignee: nobody → joe
Attachment #457754 - Attachment is obsolete: true
Attachment #457758 - Flags: review?
Attachment #457754 - Flags: review?
Attachment #457758 - Flags: review? → review?(timeless)
Comment on attachment 457758 [details] [diff] [review]
handle EINTR v2

similar code exists in js/shell/js.cpp, please patch it too
Attachment #457758 - Flags: review?(timeless) → review+
I hit this every time I start developing on a mac again. What do we need to do to get this into the tree still?
http://hg.mozilla.org/mozilla-central/rev/b7b987a52c33
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla7
You need to log in before you can comment on or make changes to this bug.