From e2ea90ce26254b721f0c01c8d0ec53d3600146fe Mon Sep 17 00:00:00 2001 From: John Ferlan Date: Tue, 22 Jan 2013 09:15:44 -0500 Subject: [PATCH] lxc: Need to initialize 'dst' It was possible to call VIR_FREE in cleanup prior to initialization --- src/lxc/lxc_driver.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/lxc/lxc_driver.c b/src/lxc/lxc_driver.c index 70b4f52afe..602f8ffcb7 100644 --- a/src/lxc/lxc_driver.c +++ b/src/lxc/lxc_driver.c @@ -3824,7 +3824,7 @@ lxcDomainDetachDeviceDiskLive(virLXCDriverPtr driver, virDomainDiskDefPtr def = NULL; virCgroupPtr group = NULL; int i, ret = -1; - char *dst; + char *dst = NULL; if (!priv->initpid) { virReportError(VIR_ERR_OPERATION_INVALID, "%s", @@ -3961,7 +3961,7 @@ lxcDomainDetachDeviceHostdevUSBLive(virLXCDriverPtr driver, virDomainHostdevDefPtr def = NULL; virCgroupPtr group = NULL; int idx, ret = -1; - char *dst; + char *dst = NULL; char *vroot; usbDevice *usb = NULL; -- GitLab