mirror of
https://github.com/libvirt/libvirt.git
synced 2026-10-02 12:20:06 -05:00
libvirtd: avoid memory leak on shutdown
* daemon/libvirtd.c (qemudRunLoop): Free any remaining client data.
This commit is contained in:
1 parent
9c65609247
commit
6d0df64821
1 file changed
+4
@@ -2403,6 +2403,10 @@ cleanup:
|
||||
server->workers[i].hasThread = 0;
|
||||
}
|
||||
VIR_FREE(server->workers);
|
||||
for (i = 0; i < server->nclients; i++)
|
||||
qemudFreeClient(server->clients[i]);
|
||||
server->nclients = 0;
|
||||
VIR_SHRINK_N(server->clients, server->nclients_max, server->nclients_max);
|
||||
|
||||
virMutexUnlock(&server->lock);
|
||||
return NULL;
|
||||
|
||||
Reference in new issue
Block a user