diff --git a/im_service.py b/im_service.py index 507aeb35d..d4bb6257a 100755 --- a/im_service.py +++ b/im_service.py @@ -381,6 +381,8 @@ def im_stop(): def get_childs(parent_id=None): + if parent_id is None: + parent_id = os.getpid() childs = [] for proc in psutil.process_iter(): if not parent_id or parent_id == proc.ppid():