Bug 1259290: Part 2 - Remove the cx from [Add|Remove]ChildWorker. r=bz
This commit is contained in:
@@ -1495,7 +1495,7 @@ RuntimeService::RegisterWorker(JSContext* aCx, WorkerPrivate* aWorkerPrivate)
|
||||
|
||||
// From here on out we must call UnregisterWorker if something fails!
|
||||
if (parent) {
|
||||
if (!parent->AddChildWorker(aCx, aWorkerPrivate)) {
|
||||
if (!parent->AddChildWorker(aWorkerPrivate)) {
|
||||
UnregisterWorker(aCx, aWorkerPrivate);
|
||||
return false;
|
||||
}
|
||||
@@ -1652,7 +1652,7 @@ RuntimeService::UnregisterWorker(JSContext* aCx, WorkerPrivate* aWorkerPrivate)
|
||||
}
|
||||
|
||||
if (parent) {
|
||||
parent->RemoveChildWorker(aCx, aWorkerPrivate);
|
||||
parent->RemoveChildWorker(aWorkerPrivate);
|
||||
}
|
||||
else if (aWorkerPrivate->IsSharedWorker()) {
|
||||
AssertIsOnMainThread();
|
||||
|
||||
@@ -5116,7 +5116,7 @@ WorkerPrivate::ModifyBusyCountFromWorker(bool aIncrease)
|
||||
}
|
||||
|
||||
bool
|
||||
WorkerPrivate::AddChildWorker(JSContext* aCx, ParentType* aChildWorker)
|
||||
WorkerPrivate::AddChildWorker(ParentType* aChildWorker)
|
||||
{
|
||||
AssertIsOnWorkerThread();
|
||||
|
||||
@@ -5142,7 +5142,7 @@ WorkerPrivate::AddChildWorker(JSContext* aCx, ParentType* aChildWorker)
|
||||
}
|
||||
|
||||
void
|
||||
WorkerPrivate::RemoveChildWorker(JSContext* aCx, ParentType* aChildWorker)
|
||||
WorkerPrivate::RemoveChildWorker(ParentType* aChildWorker)
|
||||
{
|
||||
AssertIsOnWorkerThread();
|
||||
|
||||
|
||||
@@ -1066,10 +1066,10 @@ public:
|
||||
ModifyBusyCountFromWorker(bool aIncrease);
|
||||
|
||||
bool
|
||||
AddChildWorker(JSContext* aCx, ParentType* aChildWorker);
|
||||
AddChildWorker(ParentType* aChildWorker);
|
||||
|
||||
void
|
||||
RemoveChildWorker(JSContext* aCx, ParentType* aChildWorker);
|
||||
RemoveChildWorker(ParentType* aChildWorker);
|
||||
|
||||
bool
|
||||
AddFeature(WorkerFeature* aFeature);
|
||||
|
||||
Reference in New Issue
Block a user