зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1250963 part 2. Remove the unused JSContext argument of WorkerPrivate::ModifyBusyCount. r=khuey
This commit is contained in:
Родитель
239833a69f
Коммит
f0afee106b
|
@ -471,7 +471,7 @@ private:
|
||||||
virtual bool
|
virtual bool
|
||||||
WorkerRun(JSContext* aCx, WorkerPrivate* aWorkerPrivate) override
|
WorkerRun(JSContext* aCx, WorkerPrivate* aWorkerPrivate) override
|
||||||
{
|
{
|
||||||
return aWorkerPrivate->ModifyBusyCount(aCx, mIncrease);
|
return aWorkerPrivate->ModifyBusyCount(mIncrease);
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void
|
virtual void
|
||||||
|
@ -862,7 +862,7 @@ private:
|
||||||
aWorkerPrivate->AssertIsOnParentThread();
|
aWorkerPrivate->AssertIsOnParentThread();
|
||||||
// Modify here, but not in PostRun! This busy count addition will be matched
|
// Modify here, but not in PostRun! This busy count addition will be matched
|
||||||
// by the CloseEventRunnable.
|
// by the CloseEventRunnable.
|
||||||
return aWorkerPrivate->ModifyBusyCount(aCx, true);
|
return aWorkerPrivate->ModifyBusyCount(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void
|
virtual void
|
||||||
|
@ -873,7 +873,7 @@ private:
|
||||||
if (!aDispatchResult) {
|
if (!aDispatchResult) {
|
||||||
// We couldn't dispatch to the worker, which means it's already dead.
|
// We couldn't dispatch to the worker, which means it's already dead.
|
||||||
// Undo the busy count modification.
|
// Undo the busy count modification.
|
||||||
aWorkerPrivate->ModifyBusyCount(aCx, false);
|
aWorkerPrivate->ModifyBusyCount(false);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -896,7 +896,7 @@ private:
|
||||||
WorkerRun(JSContext* aCx, WorkerPrivate* aWorkerPrivate) override
|
WorkerRun(JSContext* aCx, WorkerPrivate* aWorkerPrivate) override
|
||||||
{
|
{
|
||||||
// This busy count will be matched by the CloseEventRunnable.
|
// This busy count will be matched by the CloseEventRunnable.
|
||||||
return aWorkerPrivate->ModifyBusyCount(aCx, true) &&
|
return aWorkerPrivate->ModifyBusyCount(true) &&
|
||||||
aWorkerPrivate->Close();
|
aWorkerPrivate->Close();
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -2788,8 +2788,7 @@ WorkerPrivateParent<Derived>::Close()
|
||||||
|
|
||||||
template <class Derived>
|
template <class Derived>
|
||||||
bool
|
bool
|
||||||
WorkerPrivateParent<Derived>::ModifyBusyCount(JSContext* /* unused */,
|
WorkerPrivateParent<Derived>::ModifyBusyCount(bool aIncrease)
|
||||||
bool aIncrease)
|
|
||||||
{
|
{
|
||||||
AssertIsOnParentThread();
|
AssertIsOnParentThread();
|
||||||
|
|
||||||
|
|
|
@ -323,10 +323,8 @@ public:
|
||||||
bool
|
bool
|
||||||
Close();
|
Close();
|
||||||
|
|
||||||
// The JSContext argument can be null, since it's not used for anything. It's
|
|
||||||
// about to go away.
|
|
||||||
bool
|
bool
|
||||||
ModifyBusyCount(JSContext* /* unused */, bool aIncrease);
|
ModifyBusyCount(bool aIncrease);
|
||||||
|
|
||||||
void
|
void
|
||||||
ForgetOverridenLoadGroup(nsCOMPtr<nsILoadGroup>& aLoadGroupOut);
|
ForgetOverridenLoadGroup(nsCOMPtr<nsILoadGroup>& aLoadGroupOut);
|
||||||
|
|
|
@ -84,7 +84,7 @@ WorkerRunnable::PreDispatch(JSContext* aCx, WorkerPrivate* aWorkerPrivate)
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if (mBehavior == WorkerThreadModifyBusyCount) {
|
if (mBehavior == WorkerThreadModifyBusyCount) {
|
||||||
return aWorkerPrivate->ModifyBusyCount(aCx, true);
|
return aWorkerPrivate->ModifyBusyCount(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
|
@ -178,7 +178,7 @@ WorkerRunnable::PostDispatch(JSContext* aCx, WorkerPrivate* aWorkerPrivate,
|
||||||
|
|
||||||
if (!aDispatchResult) {
|
if (!aDispatchResult) {
|
||||||
if (mBehavior == WorkerThreadModifyBusyCount) {
|
if (mBehavior == WorkerThreadModifyBusyCount) {
|
||||||
aWorkerPrivate->ModifyBusyCount(aCx, false);
|
aWorkerPrivate->ModifyBusyCount(false);
|
||||||
}
|
}
|
||||||
if (aCx) {
|
if (aCx) {
|
||||||
JS_ReportPendingException(aCx);
|
JS_ReportPendingException(aCx);
|
||||||
|
|
Загрузка…
Ссылка в новой задаче