summaryrefslogtreecommitdiff
path: root/src/com/android
diff options
context:
space:
mode:
authorQi Wang <wangqi@google.com>2016-04-12 14:18:04 -0700
committerUsman Abdullah <uabdullah@google.com>2016-04-20 18:33:06 +0000
commit7185e261924b6e501c7c127a1674f49533165406 (patch)
tree52568a57d398c8b533026611c5f65308e8723f5f /src/com/android
parentd0db4f8941e13766b78c90432b92b4eaccf71e2c (diff)
Call correct number from missing call notification.
Change-Id: I97c8214e620378dd32f3778040f2f2b3e1cd58f0 Fix: 28068914 (cherry picked from commit 217b96bd8ccc6874d14a1be84d639ee2d9ba1802)
Diffstat (limited to 'src/com/android')
-rw-r--r--src/com/android/dialer/calllog/MissedCallNotifier.java6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/com/android/dialer/calllog/MissedCallNotifier.java b/src/com/android/dialer/calllog/MissedCallNotifier.java
index 98d02d095..20fc5d551 100644
--- a/src/com/android/dialer/calllog/MissedCallNotifier.java
+++ b/src/com/android/dialer/calllog/MissedCallNotifier.java
@@ -254,7 +254,8 @@ public class MissedCallNotifier {
intent.setAction(
CallLogNotificationsService.ACTION_CALL_BACK_FROM_MISSED_CALL_NOTIFICATION);
intent.putExtra(CallLogNotificationsService.EXTRA_MISSED_CALL_NUMBER, number);
- return PendingIntent.getService(mContext, 0, intent, 0);
+ // Use FLAG_ONE_SHOT to avoid reusing previous PendingIntent with different number.
+ return PendingIntent.getService(mContext, 0, intent, PendingIntent.FLAG_ONE_SHOT);
}
private PendingIntent createSendSmsFromNotificationPendingIntent(String number) {
@@ -262,7 +263,8 @@ public class MissedCallNotifier {
intent.setAction(
CallLogNotificationsService.ACTION_SEND_SMS_FROM_MISSED_CALL_NOTIFICATION);
intent.putExtra(CallLogNotificationsService.EXTRA_MISSED_CALL_NUMBER, number);
- return PendingIntent.getService(mContext, 0, intent, 0);
+ // Use FLAG_ONE_SHOT to avoid reusing previous PendingIntent with different number.
+ return PendingIntent.getService(mContext, 0, intent, PendingIntent.FLAG_ONE_SHOT);
}
/**