diff options
author | Vinay Sajip <vinay_sajip@yahoo.co.uk> | 2006-01-16 09:13:58 (GMT) |
---|---|---|
committer | Vinay Sajip <vinay_sajip@yahoo.co.uk> | 2006-01-16 09:13:58 (GMT) |
commit | d952041dc7e9c9520302fb1086119e356b46a645 (patch) | |
tree | 932ed6a45ccaa922b2e0e44a944a39c5a04ec910 /Lib | |
parent | 74a83e9ffbee00288bbc1ddd0e5a40e84a03b4af (diff) | |
download | cpython-d952041dc7e9c9520302fb1086119e356b46a645.zip cpython-d952041dc7e9c9520302fb1086119e356b46a645.tar.gz cpython-d952041dc7e9c9520302fb1086119e356b46a645.tar.bz2 |
TimedRotatingFileHandler now calculates next rollover from previous rollover rather than current time.
Diffstat (limited to 'Lib')
-rw-r--r-- | Lib/logging/handlers.py | 2 |
1 files changed, 1 insertions, 1 deletions
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): """ |