Merge "Fix WTF in PendingIntentRecord.unregisterCancelListenerLocked()" into pi-dev
This commit is contained in:
committed by
Android (Google) Code Review
commit
16fb966442
@@ -219,6 +219,9 @@ final class PendingIntentRecord extends IIntentSender.Stub {
|
||||
}
|
||||
|
||||
public void unregisterCancelListenerLocked(IResultReceiver receiver) {
|
||||
if (mCancelCallbacks == null) {
|
||||
return; // Already unregistered or detached.
|
||||
}
|
||||
mCancelCallbacks.unregister(receiver);
|
||||
if (mCancelCallbacks.getRegisteredCallbackCount() <= 0) {
|
||||
mCancelCallbacks = null;
|
||||
|
||||
Reference in New Issue
Block a user