Cannot compare Binder references for RC display to unregister
Cannot trust references to IRemoteControlDisplay to remain the same when removing a RemoteControlDisplay, compare the result of .asBinder() instead. Change-Id: Ib2e82aa24bd4b12804bccff94a6a0090ff83bea8
This commit is contained in:
@@ -703,7 +703,7 @@ public class RemoteControlClient
|
||||
|
||||
private void onUnplugDisplay(IRemoteControlDisplay rcd) {
|
||||
synchronized(mCacheLock) {
|
||||
if ((mRcDisplay != null) && (mRcDisplay.equals(rcd))) {
|
||||
if ((mRcDisplay != null) && (mRcDisplay.asBinder().equals(rcd.asBinder()))) {
|
||||
mRcDisplay = null;
|
||||
mArtworkExpectedWidth = ARTWORK_DEFAULT_SIZE;
|
||||
mArtworkExpectedHeight = ARTWORK_DEFAULT_SIZE;
|
||||
|
||||
Reference in New Issue
Block a user