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

Commit 5eba4251 authored by paulhu's avatar paulhu
Browse files

Make PendingIntent immutable

PacManager puts up a notification with PendingIntent, but this
PendingIntent is mutable that content can be changed by someone.
So make the PendingIntent to be immutable to fix the content.

Bug: 169790636
Test: atest FrameworksNetTests
Change-Id: I415c8ea715b8152c975a71bdd09822211fd89b5b
parent 5f7d33da
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -154,7 +154,7 @@ public class PacManager {
        mNetThreadHandler = new Handler(netThread.getLooper());

        mPacRefreshIntent = PendingIntent.getBroadcast(
                context, 0, new Intent(ACTION_PAC_REFRESH), 0);
                context, 0, new Intent(ACTION_PAC_REFRESH), PendingIntent.FLAG_IMMUTABLE);
        context.registerReceiver(new PacRefreshIntentReceiver(),
                new IntentFilter(ACTION_PAC_REFRESH));
        mConnectivityHandler = handler;