Bug 1270689 - Clear WidevineDecryptor::mCallback in WidevineDecryptor::DecryptingComplete(). r=gerald

The OnSessionClosed() callback is happening on a timer, after
WidevineDecryptor::DecryptingComplete() has been called. So mCallback could
actually be non-null because DecryptingComplete() has been called, but the
object pointed to by mCallback has been deallocated, and mCallback is a
dangling pointer.

MozReview-Commit-ID: 4xdHYRn7EAS

--HG--
extra : source : 55d79997aa3e3e2133d9155c37f4435317b44061
This commit is contained in:
Chris Pearce 2016-05-16 14:34:20 +12:00
Родитель 62b5c1031a
Коммит b4b5bfb254
1 изменённых файлов: 1 добавлений и 0 удалений

Просмотреть файл

@ -187,6 +187,7 @@ WidevineDecryptor::DecryptingComplete()
{
Log("WidevineDecryptor::DecryptingComplete() this=%p", this);
mCDM = nullptr;
mCallback = nullptr;
Release();
}