Skip to content

Commit

Permalink
Fix for Python 2.5
Browse files Browse the repository at this point in the history
Signed-off-by: Sven Velt <sven@velt.de>
  • Loading branch information
wAmpIre committed Aug 26, 2010
1 parent 1a62d51 commit 9e2702a
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion nagixsc/__init__.py
Expand Up @@ -99,7 +99,10 @@ def exec_check(host_name, service_descr, cmdline, timeout=None, timeout_returnco
if timeout:
signal.alarm(0)
try:
cmd.terminate()
if sys.version_info >= (2, 6):
cmd.terminate()
else:
os.kill(cmd.pid, 15)
except OSError:
pass

Expand Down

0 comments on commit 9e2702a

Please sign in to comment.