Midnight should mean midnight
...not noon-or-midnight. Fix the initial fstrim delay to properly refer to midnight rather than ambiguous 12-hour "zero" so that fstrim job consideration always starts overnight rather than possibly at the following day's noon, depending on when the device was booted. Bug 18076397 Change-Id: Ife3cd5bdeb14c7832b6e2a2de88dcfd1ba731b67
This commit is contained in:
@@ -98,7 +98,7 @@ public class MountServiceIdler extends JobService {
|
||||
private static Calendar tomorrowMidnight() {
|
||||
Calendar calendar = Calendar.getInstance();
|
||||
calendar.setTimeInMillis(System.currentTimeMillis());
|
||||
calendar.set(Calendar.HOUR, 0);
|
||||
calendar.set(Calendar.HOUR_OF_DAY, 0);
|
||||
calendar.set(Calendar.MINUTE, 0);
|
||||
calendar.set(Calendar.SECOND, 0);
|
||||
calendar.set(Calendar.MILLISECOND, 0);
|
||||
|
||||
Reference in New Issue
Block a user