]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
LXC: free dst before lxcDomainAttachDeviceDiskLive returns
authorChen Hanxiao <chenhanxiao@cn.fujitsu.com>
Thu, 26 Sep 2013 06:01:52 +0000 (14:01 +0800)
committerDaniel P. Berrange <berrange@redhat.com>
Tue, 18 Feb 2014 13:55:55 +0000 (13:55 +0000)
Free dst before lxcDomainAttachDeviceDiskLive returns

Signed-off-by: Chen Hanxiao <chenhanxiao@cn.fujitsu.com>
(cherry picked from commit c82513acc2e1e0b035e5e53577a34fd68a530788)

src/lxc/lxc_driver.c

index 0c3667394d21e0d454c8021b8c3ecdb4a831c2bc..6e6b82389d8e34da8389a8f7cc54256182200b87 100644 (file)
@@ -3177,6 +3177,7 @@ cleanup:
     virDomainAuditDisk(vm, NULL, def->src, "attach", ret == 0);
     if (dst && created && ret < 0)
         unlink(dst);
+    VIR_FREE(dst);
     return ret;
 }