Minor update

This commit is contained in:
Miroslav Stampar
2016-05-16 16:47:29 +02:00
parent fea5cc8579
commit 9662f4a56a
2 changed files with 5 additions and 2 deletions

View File

@@ -278,7 +278,10 @@ def main():
if threading.activeCount() > 1:
logger.debug("short delay for thread finalization")
time.sleep(0.5)
try:
time.sleep(0.5)
except KeyboardInterrupt:
pass
# Reference: http://stackoverflow.com/questions/1635080/terminate-a-multi-thread-python-program
if conf.get("threads", 0) > 1 or conf.get("dnsServer"):