Correct signals problem

This commit is contained in:
Joshua Boniface 2018-10-03 23:45:19 -04:00
parent 8195064f11
commit 168435a827
1 changed files with 2 additions and 2 deletions

View File

@ -35,12 +35,12 @@ class OSDaemon(object):
stderr=subprocess.PIPE,
)
def signal(self, signal):
def signal(self, sent_signal):
signal_map = {
'hup': signal.SIGHUP,
'int': signal.SIGINT
}
self.proc.send_signal(signal_map[signal])
self.proc.send_signal(signal_map[sent_signal])
def run_os_daemon(command_string, background=False, environment=None, return_pid=False):
command = command_string.split()