]> xenbits.xensource.com Git - 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 13:59:37 +0000 (15:59 +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.

daemon/remote.c

index 1d214784c779b40b52ce2d28d1e5d29d32532e8a..af89e60af8f27954d4e4ae052129f9a417de462f 100644 (file)
@@ -4202,6 +4202,8 @@ cleanup:
             virStorageVolFree(vols[i]);
         VIR_FREE(vols);
     }
+    if (pool)
+        virStoragePoolFree(pool);
     return rv;
 }