Closed Bug 1358320 Opened 3 years ago Closed 3 years ago
Stamp::Process Creation()'s outparam optional
TimeStamp::ProcessCreations()'s aIsInconsistent outparam is ignored by the majority of its caller. This patch makes it optional. Notably, this makes ProcessCreation() easier to use a constructor's initializer list, as is done in CorePS.
Comment on attachment 8860228 [details] [diff] [review] Make TimeStamp::ProcessCreation()'s outparam optional Whoa, that's a lot of call sites, I had no idea this had become so popular. Anyway, this should be fine since when the process uptime is inconsistent it should return 0 which should be safe for callers. I did this explicitly to fix certain intermittent tests we had that computed a negative uptime. That being said since there's so many callers that are using it to get the number-of-seconds since start or a similar measure it might be a good idea to factorize that operation into its own method (TimeStamp::Uptime()?) to make it more terse.
Attachment #8860228 - Flags: review?(gsvelto) → review+
https://hg.mozilla.org/integration/mozilla-inbound/rev/e1eb2550cb111e242ded6a12d6e50731fcefcbf6 Bug 1358320 - Make TimeStamp::ProcessCreation()'s outparam optional. r=gsvelto.
You need to log in before you can comment on or make changes to this bug.