[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

[libvirt] PATCH: Fix leak in storage driver

A recent change to keep the storage pools active upon shutdown, exposed a
minor flaw in the code which free's a virStoragePoolObj instance. It
never free's the associated volumes, since it presumed you'd never free
a pool, which was still active. A bogus assumption, causing  us to leak
memory upon daemon shutdown, thus annoying valgrind. 


diff -r 3e95abd6df89 src/storage_conf.c
--- a/src/storage_conf.c	Fri Jan 30 11:01:10 2009 +0000
+++ b/src/storage_conf.c	Fri Jan 30 11:01:29 2009 +0000
@@ -296,6 +296,8 @@ virStoragePoolObjFree(virStoragePoolObjP
     if (!obj)
+    virStoragePoolObjClearVols(obj);

|: Red Hat, Engineering, London   -o-   http://people.redhat.com/berrange/ :|
|: http://libvirt.org  -o-  http://virt-manager.org  -o-  http://ovirt.org :|
|: http://autobuild.org       -o-         http://search.cpan.org/~danberr/ :|
|: GnuPG: 7D3B9505  -o-  F3C9 553F A1DA 4AC2 5648 23C1 B3DF F742 7D3B 9505 :|

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]