mirror of https://github.com/n1nj4sec/pupy.git
Just kill zombies
In case we have some alive processes this will hang, which is not that we expect to get.
This commit is contained in:
parent
465d2c69ce
commit
690e3c162c
|
@ -157,8 +157,10 @@ class ReverseSlaveService(Service):
|
|||
raise
|
||||
|
||||
try:
|
||||
while True:
|
||||
os.waitpid(-1, os.WNOHANG)
|
||||
pid = os.waitpid(-1, os.WNOHANG)
|
||||
while pid:
|
||||
pid = os.waitpid(-1, os.WNOHANG)
|
||||
|
||||
except OSError:
|
||||
pass
|
||||
|
||||
|
|
Loading…
Reference in New Issue