- Fixed bugs introduced by refactoring

git-svn-id: https://fail2ban.svn.sourceforge.net/svnroot/fail2ban/trunk@369 a942ae1a-1317-0410-a47c-b1dcaea8d605
0.x
Cyril Jaquier 2006-09-19 21:22:27 +00:00
parent 126807dea8
commit 4b80546f10
3 changed files with 5 additions and 5 deletions

View File

@ -282,7 +282,7 @@ class Filter(JailThread):
##
# Close the log file.
def closeLogFile(self):
def __closeLogFile(self):
self.crtFilename = None
self.crtHandler.close()
@ -319,7 +319,7 @@ class Filter(JailThread):
# time.time()-self.findTime. When a failure is detected, a FailTicket
# is created and is added to the FailManager.
def __getFailures(self, filename):
def getFailures(self, filename):
ipList = dict()
logSys.debug(filename)
self.openLogFile(filename)
@ -350,7 +350,7 @@ class Filter(JailThread):
self.lastPos[filename] = self.__getFilePos()
if lastLine:
self.lastDate[filename] = self.dateDetector.getTime(lastLine)
self.closeLogFile()
self.__closeLogFile()
##
# Finds the failure in a line.

View File

@ -61,7 +61,7 @@ class FilterGamin(Filter):
logSys.debug("Got event: " + `event` + " for " + path)
if event in (gamin.GAMCreated, gamin.GAMChanged, gamin.GAMExists):
logSys.debug("File changed: " + path)
self.__getFailures(path)
self.getFailures(path)
self.modified = True

View File

@ -106,7 +106,7 @@ class FilterPoll(Filter):
# Get file modification
for file in self.getLogPath():
if self.isModified(file):
self.__getFailures(file)
self.getFailures(file)
prevModified = True
if self.modified: