Bug 1351874 - Dispatch shutdown runnable to CDMParent rather than null. r?gerald
MozReview-Commit-ID: BE5OgrgbvAT
--- a/dom/media/gmp/ChromiumCDMProxy.cpp
+++ b/dom/media/gmp/ChromiumCDMProxy.cpp
@@ -351,17 +351,17 @@ ChromiumCDMProxy::Shutdown()
mKeys.Clear();
RefPtr<gmp::ChromiumCDMParent> cdm;
{
MutexAutoLock lock(mCDMMutex);
cdm.swap(mCDM);
}
if (cdm) {
nsCOMPtr<nsIRunnable> task =
- NewRunnableMethod(mCDM, &gmp::ChromiumCDMParent::Shutdown);
+ NewRunnableMethod(cdm, &gmp::ChromiumCDMParent::Shutdown);
mGMPThread->Dispatch(task.forget());
}
}
void
ChromiumCDMProxy::RejectPromise(PromiseId aId,
nsresult aCode,
const nsCString& aReason)