зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1653638 - P3. Remove no longer necessary workaround. r=mjf,karlt
C++17 guarantees that "In a function-call expression, the expression that names the function is sequenced before every argument expression and every default argument." The order of operations in the expression s now guaranteed, we can remove the comment and the workaround. Differential Revision: https://phabricator.services.mozilla.com/D85676
This commit is contained in:
Родитель
f181df10f9
Коммит
749a1d0d03
|
@ -656,13 +656,7 @@ void AsyncDecodeWebAudio(const char* aContentType, uint8_t* aBuffer,
|
|||
WebAudioDecodeJob::UnknownError);
|
||||
aDecodeJob.mContext->Dispatch(event.forget());
|
||||
} else {
|
||||
// If we did this without a temporary:
|
||||
// task->PControllerTaskQueue()->Dispatch(task.forget())
|
||||
// we might evaluate the task.forget() before calling
|
||||
// OnPControllerTaskQueue().
|
||||
// Enforce a non-crashy order-of-operations.
|
||||
TaskQueue* taskQueue = task->PControllerTaskQueue();
|
||||
nsresult rv = taskQueue->Dispatch(task.forget());
|
||||
nsresult rv = task->PControllerTaskQueue()->Dispatch(task.forget());
|
||||
MOZ_DIAGNOSTIC_ASSERT(NS_SUCCEEDED(rv));
|
||||
Unused << rv;
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче