mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-24 21:31:04 +00:00
Bug 1439212
Make ServiceWorkerRegistrationWorkerThread::ShowNotification() check for nullptr mWorkerPrivate. r=asuth
This commit is contained in:
parent
eb78122ad1
commit
5ff28b6a7f
@ -990,6 +990,10 @@ ServiceWorkerRegistrationWorkerThread::ShowNotification(JSContext* aCx,
|
||||
const NotificationOptions& aOptions,
|
||||
ErrorResult& aRv)
|
||||
{
|
||||
if (!mWorkerPrivate) {
|
||||
aRv.Throw(NS_ERROR_DOM_INVALID_STATE_ERR);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
// Until Bug 1131324 exposes ServiceWorkerContainer on workers,
|
||||
// ShowPersistentNotification() checks for valid active worker while it is
|
||||
|
Loading…
Reference in New Issue
Block a user