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

Commit b3d02465 authored by Prashant Malani's avatar Prashant Malani Committed by Android Git Automerger
Browse files

am 9a3eacbe: Merge "Revert "Always re-establish kernel alarms when considering...

am 9a3eacbe: Merge "Revert "Always re-establish kernel alarms when considering new alarm set"" into cw-d-mr1-dev

* commit '9a3eacbe':
  Revert "Always re-establish kernel alarms when considering new alarm set"
parents cf05e318 9a3eacbe
Loading
Loading
Loading
Loading
+2 −4
Original line number Original line Diff line number Diff line
@@ -1230,8 +1230,7 @@ class AlarmManagerService extends SystemService {
        if (mAlarmBatches.size() > 0) {
        if (mAlarmBatches.size() > 0) {
            final Batch firstWakeup = findFirstWakeupBatchLocked();
            final Batch firstWakeup = findFirstWakeupBatchLocked();
            final Batch firstBatch = mAlarmBatches.get(0);
            final Batch firstBatch = mAlarmBatches.get(0);
            // always update the kernel alarms, as a backstop against missed wakeups
            if (firstWakeup != null && mNextWakeup != firstWakeup.start) {
            if (firstWakeup != null) {
                mNextWakeup = firstWakeup.start;
                mNextWakeup = firstWakeup.start;
                setLocked(ELAPSED_REALTIME_WAKEUP, firstWakeup.start);
                setLocked(ELAPSED_REALTIME_WAKEUP, firstWakeup.start);
            }
            }
@@ -1244,8 +1243,7 @@ class AlarmManagerService extends SystemService {
                nextNonWakeup = mNextNonWakeupDeliveryTime;
                nextNonWakeup = mNextNonWakeupDeliveryTime;
            }
            }
        }
        }
        // always update the kernel alarm, as a backstop against missed wakeups
        if (nextNonWakeup != 0 && mNextNonWakeup != nextNonWakeup) {
        if (nextNonWakeup != 0) {
            mNextNonWakeup = nextNonWakeup;
            mNextNonWakeup = nextNonWakeup;
            setLocked(ELAPSED_REALTIME, nextNonWakeup);
            setLocked(ELAPSED_REALTIME, nextNonWakeup);
        }
        }