Bug 831303 - Fix the the stop where we start counting the shutdown time.r=ehsan.

--HG--
extra : rebase_source : 8d00557db0872b6c192c85b7ce364e8f9838ba9b
This commit is contained in:
Rafael Ávila de Espíndola 2013-01-17 11:40:14 -05:00
parent eb4cfdf07d
commit 59be78e293
2 changed files with 7 additions and 2 deletions

View File

@ -309,8 +309,6 @@ nsAppStartup::Quit(uint32_t aMode)
if (mShuttingDown)
return NS_OK;
mozilla::RecordShutdownStartTimeStamp();
// If we're considering quitting, we will only do so if:
if (ferocity == eConsiderQuit) {
#ifdef XP_MACOSX
@ -382,6 +380,7 @@ nsAppStartup::Quit(uint32_t aMode)
}
SAMPLE_MARKER("Shutdown start");
mozilla::RecordShutdownStartTimeStamp();
mShuttingDown = true;
if (!mRestart) {
mRestart = (aMode & eRestart) != 0;

View File

@ -1997,6 +1997,12 @@ const Module kTelemetryModule = {
namespace mozilla {
void
RecordShutdownStartTimeStamp() {
#ifdef DEBUG
static bool recorded = false;
MOZ_ASSERT(!recorded);
recorded = true;
#endif
if (!Telemetry::CanRecord())
return;