[libvirt] [PATCH] Fix handling of disk backing stores with cgroups

Eric Blake eblake at redhat.com
Wed Apr 28 17:03:42 UTC 2010


On 04/28/2010 09:27 AM, Daniel P. Berrange wrote:
> +                memset(&meta, 0, sizeof(meta));
> +
> +                ret = virStorageFileGetMetadata(path, &meta);
> +
> +                if (path != vm->def->disks[i]->src)
> +                    VIR_FREE(path);
> +                path = NULL;
> +
> +                if (ret < 0)
> +                    goto cleanup;
> +
> +                path = meta.backingStore;

I had to go read virStorageFileGetMetadata to make sure there was no
leak or double-free, but after a few minutes review, I'm convinced you
did it right.

ACK.

-- 
Eric Blake   eblake at redhat.com    +1-801-349-2682
Libvirt virtualization library http://libvirt.org

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 619 bytes
Desc: OpenPGP digital signature
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20100428/ad7dae22/attachment-0001.sig>


More information about the libvir-list mailing list