summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJulia Reynolds <juliacr@google.com>2020-05-28 10:45:19 -0400
committerandroid-build-team Robot <android-build-team-robot@google.com>2020-06-10 00:35:59 +0000
commite183ab7e5a865ff1051505085b617f4f3ad4c049 (patch)
tree79459eb723dbc1c6d487516e8139fe9fe83bf950
parent81ee10241fc143ed576734268708c9943217ff8b (diff)
downloadbase-e183ab7e5a865ff1051505085b617f4f3ad4c049.tar.gz
Make intents immutable
Test: make Fixes: 154719656 Change-Id: I212ca5f1a48174ed85311b551259da314718f082 (cherry picked from commit 36b3352784ae90326a2b308542b1d2cfe18661a0) (cherry picked from commit 2a92eea73034820a20ba07cc267a326ace859d6d)
-rw-r--r--packages/SystemUI/src/com/android/systemui/statusbar/notification/InstantAppNotifier.java8
1 files changed, 4 insertions, 4 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/notification/InstantAppNotifier.java b/packages/SystemUI/src/com/android/systemui/statusbar/notification/InstantAppNotifier.java
index c67512c11922..3886f6264b16 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/notification/InstantAppNotifier.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/notification/InstantAppNotifier.java
@@ -269,7 +269,7 @@ public class InstantAppNotifier extends SystemUI
0,
new Intent(Settings.ACTION_APPLICATION_DETAILS_SETTINGS)
.setData(Uri.fromParts("package", pkg, null)),
- 0,
+ PendingIntent.FLAG_IMMUTABLE,
null,
user);
Notification.Action action =
@@ -303,7 +303,7 @@ public class InstantAppNotifier extends SystemUI
mContext,
0 /* requestCode */,
browserIntent,
- 0 /* flags */,
+ PendingIntent.FLAG_IMMUTABLE /* flags */,
null,
user);
ComponentName aiaComponent = null;
@@ -325,8 +325,8 @@ public class InstantAppNotifier extends SystemUI
.putExtra(Intent.EXTRA_LONG_VERSION_CODE, appInfo.longVersionCode)
.putExtra(Intent.EXTRA_INSTANT_APP_FAILURE, pendingIntent);
- PendingIntent webPendingIntent =
- PendingIntent.getActivityAsUser(mContext, 0, goToWebIntent, 0, null, user);
+ PendingIntent webPendingIntent = PendingIntent.getActivityAsUser(mContext, 0,
+ goToWebIntent, PendingIntent.FLAG_IMMUTABLE, null, user);
Notification.Action webAction =
new Notification.Action.Builder(
null, mContext.getString(R.string.go_to_web), webPendingIntent)