]> xenbits.xensource.com Git - libvirt.git/commit
daemonSetupNetworking: Don't leak services
authorMichal Privoznik <mprivozn@redhat.com>
Thu, 18 Jun 2015 12:11:21 +0000 (14:11 +0200)
committerMichal Privoznik <mprivozn@redhat.com>
Fri, 19 Jun 2015 09:18:08 +0000 (11:18 +0200)
commit058d18bdbce81c272c51d7a5a2eea89681d40406
tree8d9af7aae83c805113d738ae4a964ecfe3e01e5d
parent1d0fc8083c31c3f754a582c95077b510f75a5ef8
daemonSetupNetworking: Don't leak services

When setting up the daemon networking, new services are created. These
services then have sockets to listen on. Once created, the service
objects are added to corresponding server object. However, during that
process, server increases reference counter of the service object. So,
at the end of the function, we should decrease it again. This way the
service objects will have only 1 reference, but that's okay since
servers are the only objects having a reference.

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
daemon/libvirtd.c