kill self process

This commit is contained in:
Volkan Şahin 2016-04-25 16:41:22 +03:00
parent 9ffd543cfb
commit 414ac032bf

View file

@ -10,6 +10,7 @@ import signal
import sys import sys
import threading import threading
import time import time
import subprocess
from base.Scope import Scope from base.Scope import Scope
from base.config.ConfigManager import ConfigManager from base.config.ConfigManager import ConfigManager
@ -241,6 +242,7 @@ class AhenkDeamon(BaseDaemon):
scope = Scope.getInstance() scope = Scope.getInstance()
scope.getMessager().disconnect() scope.getMessager().disconnect()
# TODO kill thread # TODO kill thread
subprocess.Popen('kill -9 '+get_pid_number(), shell=True)
print('stopping ahenk') print('stopping ahenk')
else: else:
logger.error('[AhenkDeamon] Unknown command error. Command:' + params[0]) logger.error('[AhenkDeamon] Unknown command error. Command:' + params[0])