mirror of
https://github.com/fail2ban/fail2ban.git
synced 2026-03-11 08:55:31 +00:00
- Handle "AttributeError" exception in remove()
git-svn-id: https://fail2ban.svn.sourceforge.net/svnroot/fail2ban/branches/FAIL2BAN-0_5@206 a942ae1a-1317-0410-a47c-b1dcaea8d605
This commit is contained in:
parent
2c1a0785c5
commit
5556c78350
1 changed files with 3 additions and 0 deletions
|
|
@ -70,6 +70,9 @@ class PIDLock:
|
|||
logSys.debug("Removed PID lock " + self.path)
|
||||
except OSError:
|
||||
logSys.error("Unable to remove PID lock " + self.path)
|
||||
except AttributeError:
|
||||
# AttributeError if self.path wasn't specified yet
|
||||
logSys.debug("PID lock not removed because not defined yet")
|
||||
|
||||
def exists(self):
|
||||
""" Returns the current PID if Fail2Ban is running or False
|
||||
|
|
|
|||
Loading…
Reference in a new issue