Fix shutdown of LXC controller

Since we are not yet using the virNetServerPtr object for running
the event loop, we can't use virNetServerQuit(). Instead set the
global 'quit' flag in libvirt_lxc
This commit is contained in:
Daniel P. Berrange 2012-07-09 14:55:31 +01:00
parent 7ea1dd93aa
commit 97d7f02dcc

View File

@ -852,8 +852,11 @@ static void virLXCControllerSignalChildIO(virNetServerPtr server ATTRIBUTE_UNUSE
int ret;
ret = waitpid(-1, NULL, WNOHANG);
if (ret == ctrl->initpid)
virNetServerQuit(ctrl->server);
if (ret == ctrl->initpid) {
virMutexLock(&lock);
quit = true;
virMutexUnlock(&lock);
}
}