Bug 1384034 - Label UpdateTimerCallback in ServiceWorkerManager. r=bkelly

Label with SystemGroup because UpdateTimerCallback only sends an IPC message
to the parent without touching any web contents.
This commit is contained in:
Bevis Tseng 2017-08-29 17:59:01 +08:00
Родитель 9599945ea5
Коммит 8548a3c354
1 изменённых файлов: 5 добавлений и 0 удалений

Просмотреть файл

@ -34,6 +34,7 @@
#include "mozilla/ClearOnShutdown.h"
#include "mozilla/ErrorNames.h"
#include "mozilla/LoadContext.h"
#include "mozilla/SystemGroup.h"
#include "mozilla/Telemetry.h"
#include "mozilla/dom/BindingUtils.h"
#include "mozilla/dom/ContentParent.h"
@ -4312,6 +4313,10 @@ ServiceWorkerManager::ScheduleUpdateTimer(nsIPrincipal* aPrincipal,
return;
}
// Label with SystemGroup because UpdateTimerCallback only sends an IPC message
// (PServiceWorkerUpdaterConstructor) without touching any web contents.
timer->SetTarget(SystemGroup::EventTargetFor(TaskCategory::Other));
nsCOMPtr<nsITimerCallback> callback = new UpdateTimerCallback(aPrincipal,
aScope);