mirror of https://github.com/fail2ban/fail2ban
small amend (avoid possible error by close of not existing pipe)
parent
df885586d4
commit
6c6cf2a956
|
@ -270,8 +270,9 @@ class Utils():
|
||||||
if stderr is not None and stderr != '' and std_level >= logSys.getEffectiveLevel():
|
if stderr is not None and stderr != '' and std_level >= logSys.getEffectiveLevel():
|
||||||
for l in stderr.splitlines():
|
for l in stderr.splitlines():
|
||||||
logSys.log(std_level, "%x -- stderr: %r", realCmdId, uni_decode(l))
|
logSys.log(std_level, "%x -- stderr: %r", realCmdId, uni_decode(l))
|
||||||
popen.stdout.close()
|
|
||||||
popen.stderr.close()
|
if popen.stdout: popen.stdout.close()
|
||||||
|
if popen.stderr: popen.stderr.close()
|
||||||
|
|
||||||
success = False
|
success = False
|
||||||
if retcode in success_codes:
|
if retcode in success_codes:
|
||||||
|
|
Loading…
Reference in New Issue