Merge "Apply FLAG_IMMUTABLE to the PendingIntent in NetworkStatService.java"
This commit is contained in:
committed by
Android (Google) Code Review
commit
1469d40aa4
@@ -552,7 +552,8 @@ public class NetworkStatsService extends INetworkStatsService.Stub {
|
|||||||
|
|
||||||
// schedule periodic pall alarm based on {@link NetworkStatsSettings#getPollInterval()}.
|
// schedule periodic pall alarm based on {@link NetworkStatsSettings#getPollInterval()}.
|
||||||
final PendingIntent pollIntent =
|
final PendingIntent pollIntent =
|
||||||
PendingIntent.getBroadcast(mContext, 0, new Intent(ACTION_NETWORK_STATS_POLL), 0);
|
PendingIntent.getBroadcast(mContext, 0, new Intent(ACTION_NETWORK_STATS_POLL),
|
||||||
|
PendingIntent.FLAG_IMMUTABLE);
|
||||||
|
|
||||||
final long currentRealtime = SystemClock.elapsedRealtime();
|
final long currentRealtime = SystemClock.elapsedRealtime();
|
||||||
mAlarmManager.setInexactRepeating(AlarmManager.ELAPSED_REALTIME, currentRealtime,
|
mAlarmManager.setInexactRepeating(AlarmManager.ELAPSED_REALTIME, currentRealtime,
|
||||||
|
|||||||
Reference in New Issue
Block a user