diff --git a/jetty-util/src/main/java/org/eclipse/jetty/util/RolloverFileOutputStream.java b/jetty-util/src/main/java/org/eclipse/jetty/util/RolloverFileOutputStream.java index 3ee1f124c5c..cfefd9c9418 100644 --- a/jetty-util/src/main/java/org/eclipse/jetty/util/RolloverFileOutputStream.java +++ b/jetty-util/src/main/java/org/eclipse/jetty/util/RolloverFileOutputStream.java @@ -210,9 +210,8 @@ public class RolloverFileOutputStream extends FilterOutputStream private void scheduleNextRollover() { - long lastMs = midnight.toInstant().toEpochMilli(); midnight = nextMidnight(midnight); - __rollover.schedule(_rollTask,midnight.toInstant().toEpochMilli() - lastMs); + __rollover.schedule(_rollTask,midnight.toInstant().toEpochMilli() - System.currentTimeMillis()); } /* ------------------------------------------------------------ */