Bug 941789 - Protect binderDied() by mutex. r=doublec

--HG--
extra : rebase_source : 9538d1cbc107f597ccc3237fce8da26040707ce6
This commit is contained in:
Sotaro Ikeda 2013-12-04 17:44:36 -05:00
parent e1bb3e926a
commit 985e08eeb9

View File

@ -46,6 +46,7 @@ MediaResourceManagerService::~MediaResourceManagerService()
void MediaResourceManagerService::binderDied(const wp<IBinder>& who) void MediaResourceManagerService::binderDied(const wp<IBinder>& who)
{ {
if (who != NULL) { if (who != NULL) {
Mutex::Autolock autoLock(mLock);
sp<IBinder> binder = who.promote(); sp<IBinder> binder = who.promote();
if (binder != NULL) { if (binder != NULL) {
cancelClientLocked(binder); cancelClientLocked(binder);