]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
daemon: fix leak after listing all volumes
authorJán Tomko <jtomko@redhat.com>
Fri, 12 Apr 2013 15:30:56 +0000 (17:30 +0200)
committerJán Tomko <jtomko@redhat.com>
Thu, 16 May 2013 14:00:14 +0000 (16:00 +0200)
CVE-2013-1962

remoteDispatchStoragePoolListAllVolumes wasn't freeing the pool.
The pool also held a reference to the connection, preventing it from
getting freed and closing the netcf interface driver, which held two
sockets open.
(cherry picked from commit ca697e90d5bd6a6dfb94bfb6d4438bdf9a44b739)

daemon/remote.c

index 35411f150fca0afacd0553df83e946861e02c127..4b89df3f39457b972060f867a0ce57488b9a3187 100644 (file)
@@ -4212,6 +4212,8 @@ cleanup:
             virStorageVolFree(vols[i]);
         VIR_FREE(vols);
     }
+    if (pool)
+        virStoragePoolFree(pool);
     return rv;
 }