mirror of https://github.com/fail2ban/fail2ban
ENH: dont execute empty commands
parent
13a12589a3
commit
4d1c060e21
|
@ -359,6 +359,10 @@ class Action:
|
||||||
#@staticmethod
|
#@staticmethod
|
||||||
def executeCmd(realCmd):
|
def executeCmd(realCmd):
|
||||||
logSys.debug(realCmd)
|
logSys.debug(realCmd)
|
||||||
|
if realCmd is None or realCmd == "":
|
||||||
|
logSys.debug("Nothing to do")
|
||||||
|
return True
|
||||||
|
|
||||||
_cmd_lock.acquire()
|
_cmd_lock.acquire()
|
||||||
try: # Try wrapped within another try needed for python version < 2.5
|
try: # Try wrapped within another try needed for python version < 2.5
|
||||||
try:
|
try:
|
||||||
|
|
Loading…
Reference in New Issue