Petr Horáček has uploaded a new change for review.

Change subject: ipwrapped: event monitor, docs update + proc.wait
......................................................................

ipwrapped: event monitor, docs update + proc.wait

Monitor's documentation updated - monitor had to be stopped,
otherwise we leak a process.

proc.kill() function alone lefts zombies, so i added proc.wait()
after it.

Change-Id: I6e7ed0a0dea368206b7ee94482251ae5e4fa7259
Signed-off-by: Petr Horáček <[email protected]>
---
M lib/vdsm/ipwrapper.py
1 file changed, 2 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/54/31854/1

diff --git a/lib/vdsm/ipwrapper.py b/lib/vdsm/ipwrapper.py
index 4a5f284..c052d23 100644
--- a/lib/vdsm/ipwrapper.py
+++ b/lib/vdsm/ipwrapper.py
@@ -604,6 +604,7 @@
         mon.start()
         for event in mon:
             handle event
+        mon.stop()
 
     Note that the underlying `ip monitor` process is killed when its controlled
     thread dies, so as not to leave stray processes when Vdsm crahsed.
@@ -631,6 +632,7 @@
     def stop(self):
         if not self.stopped:
             self.proc.kill()
+            self.proc.wait()
             self.stopped = True
 
     @classmethod


-- 
To view, visit http://gerrit.ovirt.org/31854
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I6e7ed0a0dea368206b7ee94482251ae5e4fa7259
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Petr Horáček <[email protected]>
_______________________________________________
vdsm-patches mailing list
[email protected]
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches

Reply via email to