Bug 1039884 - Let ControlMessages added by runnables in stable state be run during shutdown. r=roc r=karlt

This commit is contained in:
Andreas Pehrson 2015-01-08 06:21:00 +01:00
parent b173507d67
commit 03363ed023

View File

@ -1713,9 +1713,6 @@ MediaStreamGraphImpl::RunInStableState(bool aSourceIsMSG)
mPostedRunInStableState = false;
}
for (uint32_t i = 0; i < runnables.Length(); ++i) {
runnables[i]->Run();
}
for (uint32_t i = 0; i < controlMessagesToRunDuringShutdown.Length(); ++i) {
controlMessagesToRunDuringShutdown[i]->RunDuringShutdown();
}
@ -1724,6 +1721,10 @@ MediaStreamGraphImpl::RunInStableState(bool aSourceIsMSG)
mCanRunMessagesSynchronously = mDetectedNotRunning &&
mLifecycleState >= LIFECYCLE_WAITING_FOR_THREAD_SHUTDOWN;
#endif
for (uint32_t i = 0; i < runnables.Length(); ++i) {
runnables[i]->Run();
}
}