easy-fix: reset fail2ban link to python, if it targeted unavailable file

pull/1510/head
sebres 2016-08-12 21:32:18 +02:00
parent 2e530fcf72
commit eb72660eee
1 changed files with 1 additions and 1 deletions

View File

@ -32,7 +32,7 @@ def updatePyExec(bindir, executable=None):
executable = sys.executable
pypath = os.path.join(bindir, 'fail2ban-python')
# if not exists or point to another version - update link:
isfile = os.path.isfile(pypath)
isfile = os.path.isfile(os.path.realpath(pypath))
if not isfile or os.path.realpath(pypath) != os.path.realpath(executable):
if isfile:
os.unlink(pypath)