Set pending intent for physical keyboard connection as immutable.

In InputManagerService, set the pending intent of physical keyboard layout notification to be immutable.

Bug: 153878642
Change-Id: I8fb745f7e31dbe3e18ca8547bf75837ecf5176cd
This commit is contained in:
Chris Ye
2020-04-21 16:03:36 -07:00
parent 6e9ee1c78f
commit 6ae552650c

View File

@@ -1069,7 +1069,7 @@ public class InputManagerService extends IInputManager.Stub
| Intent.FLAG_ACTIVITY_RESET_TASK_IF_NEEDED
| Intent.FLAG_ACTIVITY_CLEAR_TOP);
final PendingIntent keyboardLayoutIntent = PendingIntent.getActivityAsUser(mContext, 0,
intent, 0, null, UserHandle.CURRENT);
intent, PendingIntent.FLAG_IMMUTABLE, null, UserHandle.CURRENT);
Resources r = mContext.getResources();
Notification notification =