Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 5117aa28 authored by Tony Wickham's avatar Tony Wickham
Browse files

Set PendingIntent as FLAG_IMMUTABLE

Test: compiles
Fixes: 174161910
Change-Id: I3e06e41aafc97670b7aa9ed0d873b69eaf1c635c
parent 348791b8
Loading
Loading
Loading
Loading
+1 −3
Original line number Original line Diff line number Diff line
@@ -385,10 +385,8 @@ public class PluginInstanceManager<T extends Plugin> {
                    }
                    }
                    Intent i = new Intent(PluginManagerImpl.DISABLE_PLUGIN).setData(
                    Intent i = new Intent(PluginManagerImpl.DISABLE_PLUGIN).setData(
                            Uri.parse("package://" + component.flattenToString()));
                            Uri.parse("package://" + component.flattenToString()));
                    // TODO(b/174161910) Please replace FLAG_MUTABLE_UNAUDITED below
                    // with either FLAG_IMMUTABLE (recommended) or FLAG_MUTABLE.
                    PendingIntent pi = PendingIntent.getBroadcast(mContext, 0, i,
                    PendingIntent pi = PendingIntent.getBroadcast(mContext, 0, i,
                            PendingIntent.FLAG_MUTABLE_UNAUDITED);
                            PendingIntent.FLAG_IMMUTABLE);
                    nb.addAction(new Action.Builder(null, "Disable plugin", pi).build());
                    nb.addAction(new Action.Builder(null, "Disable plugin", pi).build());
                    mContext.getSystemService(NotificationManager.class)
                    mContext.getSystemService(NotificationManager.class)
                            .notify(SystemMessage.NOTE_PLUGIN, nb.build());
                            .notify(SystemMessage.NOTE_PLUGIN, nb.build());