Closed
Bug 1232285
Opened 9 years ago
Closed 9 years ago
The Terminator's notion of ticks is incorrect
Categories
(Toolkit :: Async Tooling, defect)
Toolkit
Async Tooling
Tracking
()
RESOLVED
FIXED
mozilla46
Tracking | Status | |
---|---|---|
firefox46 | --- | fixed |
People
(Reporter: Yoric, Assigned: tvaleev, Mentored)
References
(Blocks 1 open bug)
Details
(Whiteboard: [lang=c++])
Attachments
(1 file, 2 obsolete files)
2.90 KB,
patch
|
Details | Diff | Splinter Review |
In nsTerminator.cpp, we currently hardcode TICK_DURATION = 1000, assuming that one tick is one millisecond. That's probably not true on all platforms. Rather, we should define `tick_duration = PR_MillisecondsToInterval(1000)` to get the correct value for the platform.
Reporter | ||
Comment 2•9 years ago
|
||
Comment on attachment 8698459 [details] [diff] [review] bug-1232285-fix-0.1.patch Review of attachment 8698459 [details] [diff] [review]: ----------------------------------------------------------------- Actually, that's not exactly what I want. Define `TICKS_DURATION` is used twice in the code. I'd like to replace the global define with a local constant `ticksDuration` defined from `PR_MillisecondsToInterval(1000)`.
Attachment #8698459 -
Flags: review?(dteller) → feedback+
Assignee | ||
Comment 3•9 years ago
|
||
Attachment #8698459 -
Attachment is obsolete: true
Attachment #8699010 -
Flags: review?(dteller)
Reporter | ||
Updated•9 years ago
|
Assignee: nobody → tvaleev
Reporter | ||
Comment 4•9 years ago
|
||
Comment on attachment 8699010 [details] [diff] [review] bug-1232285-fix-0.2.patch Review of attachment 8699010 [details] [diff] [review]: ----------------------------------------------------------------- Looks good to me. Just don't forget to change the commit message to add ",r=Yoric" at the end. Let's run this through the tests: https://treeherder.mozilla.org/#/jobs?repo=try&revision=ac274be0103f Note that I'll be away for ~2 weeks so you may need to find someone else to land this code. ::: toolkit/components/terminator/nsTerminator.cpp @@ +126,5 @@ > uint32_t crashAfterTicks = options->crashAfterTicks; > options = nullptr; > > const uint32_t timeToLive = crashAfterTicks; > + const uint32_t ticksDuration = PR_MillisecondsToInterval(1000); This should work, but let's make it `PRIntervalTime` instead of `uint32_t`.
Attachment #8699010 -
Flags: review?(dteller) → review+
Assignee | ||
Comment 5•9 years ago
|
||
Attachment #8699010 -
Attachment is obsolete: true
Assignee | ||
Comment 6•9 years ago
|
||
Hi! Do you know who can land this code?
Flags: needinfo?(vladan.bugzilla)
Flags: needinfo?(nfroyd)
Comment 8•9 years ago
|
||
(In reply to Timur Valeev from comment #6) > Hi! Do you know who can land this code? Landed, thanks! (For future patches, you can set the checkin-needed keyword after posting a successful try run URL to the bug.)
Flags: needinfo?(vladan.bugzilla)
Flags: needinfo?(nfroyd)
Comment 9•9 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/15e06810ae30
Status: NEW → RESOLVED
Closed: 9 years ago
status-firefox46:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla46
You need to log in
before you can comment on or make changes to this bug.
Description
•