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

Commit 29e4b1b5 authored by Suprabh Shukla's avatar Suprabh Shukla Committed by Automerger Merge Worker
Browse files

Merge "Fix NPE and turn on logging for device-idle alarms" into sc-dev am: ff5792fc

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/13432182

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ic490315f93de04062e2abbe07536143c2b45d995
parents 97933e6d ff5792fc
Loading
Loading
Loading
Loading
+6 −5
Original line number Diff line number Diff line
@@ -151,7 +151,8 @@ public class AlarmManagerService extends SystemService {
    static final boolean DEBUG_BG_LIMIT = localLOGV || false;
    static final boolean DEBUG_STANDBY = localLOGV || false;
    static final boolean RECORD_ALARMS_IN_HISTORY = true;
    static final boolean RECORD_DEVICE_IDLE_ALARMS = false;
    // TODO(b/178484639) : Turn off once alarms and reminders work is complete.
    static final boolean RECORD_DEVICE_IDLE_ALARMS = true;
    static final String TIMEZONE_PROPERTY = "persist.sys.timezone";

    static final int TICK_HISTORY_DEPTH = 10;
@@ -1731,8 +1732,8 @@ public class AlarmManagerService extends SystemService {
            if (RECORD_DEVICE_IDLE_ALARMS) {
                IdleDispatchEntry ent = new IdleDispatchEntry();
                ent.uid = a.uid;
                ent.pkg = a.operation.getCreatorPackage();
                ent.tag = a.operation.getTag("");
                ent.pkg = a.sourcePackage;
                ent.tag = a.statsTag;
                ent.op = "START IDLE";
                ent.elapsedRealtime = mInjector.getElapsedRealtime();
                ent.argRealtime = a.getWhenElapsed();
@@ -3151,8 +3152,8 @@ public class AlarmManagerService extends SystemService {
                if (RECORD_DEVICE_IDLE_ALARMS) {
                    IdleDispatchEntry ent = new IdleDispatchEntry();
                    ent.uid = alarm.uid;
                    ent.pkg = alarm.operation.getCreatorPackage();
                    ent.tag = alarm.operation.getTag("");
                    ent.pkg = alarm.sourcePackage;
                    ent.tag = alarm.statsTag;
                    ent.op = "END IDLE";
                    ent.elapsedRealtime = mInjector.getElapsedRealtime();
                    ent.argRealtime = alarm.getWhenElapsed();