From d952041dc7e9c9520302fb1086119e356b46a645 Mon Sep 17 00:00:00 2001 From: Vinay Sajip Date: Mon, 16 Jan 2006 09:13:58 +0000 Subject: TimedRotatingFileHandler now calculates next rollover from previous rollover rather than current time. --- Lib/logging/handlers.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Lib/logging/handlers.py b/Lib/logging/handlers.py index 6225f17..c6b526a 100644 --- a/Lib/logging/handlers.py +++ b/Lib/logging/handlers.py @@ -282,7 +282,7 @@ class TimedRotatingFileHandler(BaseRotatingHandler): self.stream = codecs.open(self.baseFilename, 'w', self.encoding) else: self.stream = open(self.baseFilename, 'w') - self.rolloverAt = int(time.time()) + self.interval + self.rolloverAt = self.rolloverAt + self.interval class SocketHandler(logging.Handler): """ -- cgit v0.12