Fix parsing of log files

This commit is contained in:
Nedko Arnaudov 2010-07-25 02:42:56 +03:00
parent d70fc9fa25
commit f4d4a23d60
1 changed files with 1 additions and 1 deletions

View File

@ -56,7 +56,7 @@ def read_last(lfile, lines):
while pos >= 0 and backlog_size <= lines:
lfile.seek(pos, 0)
s = lfile.read(chunk_size)
pos = pos - 10000
pos = pos - chunk_size
backlog_size += s.count("\n")
backlog = s + backlog
backlog = backlog.strip().split("\n")