From fddce1cbdc3c2ce95b7155dc27fcb524ec3c2119 Mon Sep 17 00:00:00 2001 From: Cyril Jaquier Date: Thu, 22 Mar 2007 22:18:46 +0000 Subject: [PATCH] - Clean up resources. Does not seem to free resources correctly. Gamin bug??? git-svn-id: https://fail2ban.svn.sourceforge.net/svnroot/fail2ban/trunk@564 a942ae1a-1317-0410-a47c-b1dcaea8d605 --- server/filtergamin.py | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/server/filtergamin.py b/server/filtergamin.py index d0f8adcb..bb5b00b3 100644 --- a/server/filtergamin.py +++ b/server/filtergamin.py @@ -117,5 +117,15 @@ class FilterGamin(Filter): time.sleep(self.getSleepTime()) else: time.sleep(self.getSleepTime()) + # Cleanup Gamin + self.__cleanup() logSys.debug(self.jail.getName() + ": filter terminated") return True + + ## + # Desallocates the resources used by Gamin. + + def __cleanup(self): + for path in Filter.getLogPath(self): + self.monitor.stop_watch(path) + del self.monitor