diff --git a/git-hooks/qdoc-bot b/git-hooks/qdoc-bot index 3a81bc975f87173a2d58d24305c146c1fbd16dc9..fd959b4ed9e2a959c2d364453ea11753e90c1200 100755 --- a/git-hooks/qdoc-bot +++ b/git-hooks/qdoc-bot @@ -382,10 +382,15 @@ def watcher(): except: pass except: - # an error occured let's restart in 15 sec logging.critical("WATCHER RESTART because of: %s", sys.exc_info()) + finally: + # an error occurred let's restart in 15 sec import time time.sleep(15) + try: + ssh.kill() + except: # swallow all errors, we do not care anymore + pass if __name__== "__main__":