daemon: Unlink unix socket paths on shutdown

This patch introduces a internal RPC API "virNetServerClose", which
is standalone with "virNetServerFree".  it closes all the socket fds,
and unlinks the unix socket paths, regardless of whether the socket
is still referenced or not.

This is to address regression bug:
https://bugzilla.redhat.com/show_bug.cgi?id=725702
This commit is contained in:
Osier Yang
2011-08-04 16:54:58 +08:00
parent 02eab9cefd
commit ae0dcbc413
7 changed files with 55 additions and 0 deletions

View File

@@ -1558,6 +1558,7 @@ int main(int argc, char **argv) {
cleanup:
virNetServerProgramFree(remoteProgram);
virNetServerProgramFree(qemuProgram);
virNetServerClose(srv);
virNetServerFree(srv);
if (statuswrite != -1) {
if (ret != 0) {