Indent top-level labels by one space in src/conf/

This commit is contained in:
Ján Tomko 2014-03-25 07:48:31 +01:00
parent 56e5a9177e
commit df2013fad0
21 changed files with 264 additions and 264 deletions

View File

@ -428,7 +428,7 @@ virCapabilitiesAddGuest(virCapsPtr caps,
return guest;
error:
error:
virCapabilitiesFreeGuest(guest);
return NULL;
}
@ -477,7 +477,7 @@ virCapabilitiesAddGuestDomain(virCapsGuestPtr guest,
return dom;
error:
error:
virCapabilitiesFreeGuestDomain(dom);
return NULL;
}
@ -552,7 +552,7 @@ virCapabilitiesHostSecModelAddBaseLabel(virCapsHostSecModelPtr secmodel,
return 0;
no_memory:
no_memory:
VIR_FREE(l);
VIR_FREE(t);
return -1;

View File

@ -168,7 +168,7 @@ virCPUDefCopy(const virCPUDef *cpu)
return copy;
error:
error:
virCPUDefFree(copy);
return NULL;
}
@ -472,13 +472,13 @@ virCPUDefParseXML(xmlNodePtr node,
}
}
cleanup:
cleanup:
VIR_FREE(fallback);
VIR_FREE(vendor_id);
VIR_FREE(nodes);
return def;
error:
error:
virCPUDefFree(def);
def = NULL;
goto cleanup;
@ -499,9 +499,9 @@ virCPUDefFormat(virCPUDefPtr def,
return virBufferContentAndReset(&buf);
no_memory:
no_memory:
virReportOOMError();
cleanup:
cleanup:
virBufferFreeAndReset(&buf);
return NULL;
}
@ -820,6 +820,6 @@ virCPUDefIsEqual(virCPUDefPtr src,
identical = true;
cleanup:
cleanup:
return identical;
}

View File

@ -106,7 +106,7 @@ virDevicePCIAddressParseXML(xmlNodePtr node,
ret = 0;
cleanup:
cleanup:
VIR_FREE(domain);
VIR_FREE(bus);
VIR_FREE(slot);

View File

@ -128,7 +128,7 @@ virDomainAuditDisk(virDomainObjPtr vm,
virt, reason, vmname, uuidstr,
oldsrc, newsrc);
cleanup:
cleanup:
VIR_FREE(vmname);
VIR_FREE(oldsrc);
VIR_FREE(newsrc);
@ -209,13 +209,13 @@ virDomainAuditRNG(virDomainObjPtr vm,
virt, reason, vmname, uuidstr,
oldsrc, newsrc);
cleanup:
cleanup:
VIR_FREE(vmname);
VIR_FREE(oldsrc);
VIR_FREE(newsrc);
return;
no_memory:
no_memory:
VIR_WARN("OOM while encoding audit message");
goto cleanup;
}
@ -261,7 +261,7 @@ virDomainAuditFS(virDomainObjPtr vm,
virt, reason, vmname, uuidstr,
oldsrc, newsrc);
cleanup:
cleanup:
VIR_FREE(vmname);
VIR_FREE(oldsrc);
VIR_FREE(newsrc);
@ -345,7 +345,7 @@ virDomainAuditNetDevice(virDomainDefPtr vmDef, virDomainNetDefPtr netDef,
"virt=%s resrc=net reason=open %s uuid=%s net=%s %s rdev=%s",
virt, vmname, uuidstr, macstr, dev_name, VIR_AUDIT_STR(rdev));
cleanup:
cleanup:
VIR_FREE(vmname);
VIR_FREE(dev_name);
VIR_FREE(rdev);
@ -469,7 +469,7 @@ virDomainAuditHostdev(virDomainObjPtr vm, virDomainHostdevDefPtr hostdev,
goto cleanup;
}
cleanup:
cleanup:
VIR_FREE(vmname);
VIR_FREE(device);
VIR_FREE(address);
@ -530,7 +530,7 @@ virDomainAuditRedirdev(virDomainObjPtr vm, virDomainRedirdevDefPtr redirdev,
virDomainRedirdevBusTypeToString(redirdev->bus),
device);
cleanup:
cleanup:
VIR_FREE(vmname);
VIR_FREE(device);
VIR_FREE(address);
@ -583,7 +583,7 @@ virDomainAuditTPM(virDomainObjPtr vm, virDomainTPMDefPtr tpm,
break;
}
cleanup:
cleanup:
VIR_FREE(vmname);
VIR_FREE(device);
}
@ -704,7 +704,7 @@ virDomainAuditCgroupPath(virDomainObjPtr vm, virCgroupPtr cgroup,
virDomainAuditCgroup(vm, cgroup, reason, extra, rc == 0);
cleanup:
cleanup:
VIR_FREE(extra);
VIR_FREE(detail);
VIR_FREE(rdev);

View File

@ -991,7 +991,7 @@ virDomainBlkioDeviceParseXML(xmlNodePtr root,
return 0;
error:
error:
VIR_FREE(c);
VIR_FREE(dev->path);
return -1;
@ -1360,7 +1360,7 @@ virDomainDiskHostDefCopy(size_t nhosts,
return ret;
error:
error:
virDomainDiskHostDefFree(nhosts, ret);
return NULL;
}
@ -2049,7 +2049,7 @@ virDomainVcpuPinDefCopy(virDomainVcpuPinDefPtr *src, int nvcpupin)
return ret;
error:
error:
if (ret) {
for (i = 0; i < nvcpupin; i++) {
if (ret[i]) {
@ -2298,7 +2298,7 @@ virDomainObjNew(virDomainXMLOptionPtr xmlopt)
VIR_DEBUG("obj=%p", domain);
return domain;
error:
error:
virObjectUnref(domain);
return NULL;
}
@ -2439,10 +2439,10 @@ virDomainObjListAddLocked(virDomainObjListPtr doms,
return NULL;
}
}
cleanup:
cleanup:
return vm;
error:
error:
virObjectUnlock(vm);
vm = NULL;
goto cleanup;
@ -2496,7 +2496,7 @@ virDomainObjSetDefTransient(virCapsPtr caps,
goto out;
ret = 0;
out:
out:
return ret;
}
@ -2571,7 +2571,7 @@ virDomainLiveConfigHelperMethod(virCapsPtr caps,
ret = 0;
cleanup:
cleanup:
return ret;
}
@ -2988,7 +2988,7 @@ virDomainDefRejectDuplicateControllers(virDomainDefPtr def)
}
ret = 0;
cleanup:
cleanup:
for (i = 0; i < nbitmaps; i++)
virBitmapFree(bitmaps[i]);
return ret;
@ -3451,7 +3451,7 @@ virDomainDeviceDriveAddressParseXML(xmlNodePtr node,
ret = 0;
cleanup:
cleanup:
VIR_FREE(controller);
VIR_FREE(bus);
VIR_FREE(target);
@ -3498,7 +3498,7 @@ virDomainDeviceVirtioSerialAddressParseXML(
ret = 0;
cleanup:
cleanup:
VIR_FREE(controller);
VIR_FREE(bus);
VIR_FREE(port);
@ -3556,7 +3556,7 @@ virDomainDeviceCCWAddressParseXML(xmlNodePtr node,
ret = 0;
cleanup:
cleanup:
VIR_FREE(cssid);
VIR_FREE(ssid);
VIR_FREE(devno);
@ -3591,7 +3591,7 @@ virDomainDeviceCcidAddressParseXML(xmlNodePtr node,
ret = 0;
cleanup:
cleanup:
VIR_FREE(controller);
VIR_FREE(slot);
return ret;
@ -3632,7 +3632,7 @@ virDomainDeviceUSBAddressParseXML(xmlNodePtr node,
ret = 0;
cleanup:
cleanup:
VIR_FREE(bus);
VIR_FREE(port);
return ret;
@ -3660,7 +3660,7 @@ virDomainDeviceSpaprVioAddressParseXML(xmlNodePtr node,
}
ret = 0;
cleanup:
cleanup:
VIR_FREE(reg);
return ret;
}
@ -3685,7 +3685,7 @@ virDomainDeviceUSBMasterParseXML(xmlNodePtr node,
ret = 0;
cleanup:
cleanup:
VIR_FREE(startport);
return ret;
}
@ -3727,7 +3727,7 @@ virDomainDeviceBootParseXML(xmlNodePtr node,
*bootIndex = boot;
ret = 0;
cleanup:
cleanup:
VIR_FREE(order);
return ret;
}
@ -3760,7 +3760,7 @@ virDomainDeviceISAAddressParseXML(xmlNodePtr node,
}
ret = 0;
cleanup:
cleanup:
VIR_FREE(iobase);
VIR_FREE(irq);
return ret;
@ -3911,7 +3911,7 @@ virDomainDeviceInfoParseXML(xmlNodePtr node,
ret = 0;
cleanup:
cleanup:
if (ret == -1)
VIR_FREE(info->alias);
VIR_FREE(type);
@ -4074,7 +4074,7 @@ virDomainHostdevSubsysUsbDefParseXML(xmlNodePtr node,
}
ret = 0;
out:
out:
return ret;
}
@ -4161,7 +4161,7 @@ virDomainHostdevSubsysPciDefParseXML(xmlNodePtr node,
}
ret = 0;
out:
out:
return ret;
}
@ -4246,7 +4246,7 @@ virDomainHostdevSubsysScsiDefParseXML(xmlNodePtr node,
}
ret = 0;
cleanup:
cleanup:
VIR_FREE(bus);
VIR_FREE(target);
VIR_FREE(unit);
@ -4502,7 +4502,7 @@ virDomainHostdevDefParseXMLSubsys(xmlNodePtr node,
}
ret = 0;
error:
error:
VIR_FREE(managed);
VIR_FREE(sgio);
VIR_FREE(backendStr);
@ -4578,7 +4578,7 @@ virDomainHostdevDefParseXMLCaps(xmlNodePtr node ATTRIBUTE_UNUSED,
goto error;
}
ret = 0;
error:
error:
return ret;
}
@ -4803,7 +4803,7 @@ virSecurityLabelDefParseXML(xmlXPathContextPtr ctxt,
return def;
error:
error:
virSecurityLabelDefFree(def);
return NULL;
}
@ -4884,7 +4884,7 @@ virSecurityLabelDefsParseXML(virDomainDefPtr def,
return 0;
error:
error:
ctxt->node = saved_node;
for (; i > 0; i--) {
virSecurityLabelDefFree(def->seclabels[i - 1]);
@ -4991,7 +4991,7 @@ virSecurityDeviceLabelDefParseXML(virSecurityDeviceLabelDefPtr **seclabels_rtn,
return 0;
error:
error:
for (i = 0; i < nseclabels; i++) {
virSecurityDeviceLabelDefFree(seclabels[i]);
}
@ -5056,7 +5056,7 @@ virDomainLeaseDefParseXML(xmlNodePtr node)
def->path = path;
path = key = lockspace = NULL;
cleanup:
cleanup:
VIR_FREE(lockspace);
VIR_FREE(key);
VIR_FREE(path);
@ -5112,7 +5112,7 @@ virDomainDiskSourcePoolDefParse(xmlNodePtr node,
source = NULL;
ret = 0;
cleanup:
cleanup:
virDomainDiskSourcePoolDefFree(source);
VIR_FREE(mode);
return ret;
@ -5239,7 +5239,7 @@ virDomainDiskSourceDefParse(xmlNodePtr node,
ret = 0;
cleanup:
cleanup:
virDomainDiskHostDefClear(&host);
VIR_FREE(protocol);
VIR_FREE(transport);
@ -6011,7 +6011,7 @@ virDomainDiskDefParseXML(virDomainXMLOptionPtr xmlopt,
&& virDomainDiskDefAssignAddress(xmlopt, def) < 0)
goto error;
cleanup:
cleanup:
VIR_FREE(bus);
VIR_FREE(type);
VIR_FREE(snapshot);
@ -6052,7 +6052,7 @@ cleanup:
ctxt->node = save_ctxt;
return def;
error:
error:
virDomainDiskDefFree(def);
def = NULL;
goto cleanup;
@ -6105,7 +6105,7 @@ virDomainParseScaledValue(const char *xpath,
*val = bytes;
ret = 1;
cleanup:
cleanup:
VIR_FREE(xpath_full);
VIR_FREE(unit);
return ret;
@ -6294,7 +6294,7 @@ virDomainControllerDefParseXML(xmlNodePtr node,
goto error;
}
cleanup:
cleanup:
ctxt->node = saved;
VIR_FREE(type);
VIR_FREE(idx);
@ -6475,7 +6475,7 @@ virDomainFSDefParseXML(xmlNodePtr node,
if (virDomainDeviceInfoParseXML(node, NULL, &def->info, flags) < 0)
goto error;
cleanup:
cleanup:
ctxt->node = save_node;
VIR_FREE(type);
VIR_FREE(fsdriver);
@ -6620,7 +6620,7 @@ virDomainActualNetDefParseXML(xmlNodePtr node,
*def = actual;
actual = NULL;
ret = 0;
error:
error:
VIR_FREE(type);
VIR_FREE(mode);
VIR_FREE(addrtype);
@ -7109,7 +7109,7 @@ virDomainNetDefParseXML(virDomainXMLOptionPtr xmlopt,
goto error;
}
cleanup:
cleanup:
ctxt->node = oldnode;
VIR_FREE(macaddr);
VIR_FREE(network);
@ -7138,7 +7138,7 @@ cleanup:
return def;
error:
error:
virDomainNetDefFree(def);
def = NULL;
goto cleanup;
@ -7293,7 +7293,7 @@ virDomainChrDefParseTargetXML(virDomainChrDefPtr def,
ret = 0;
error:
error:
VIR_FREE(targetType);
VIR_FREE(addrStr);
VIR_FREE(portStr);
@ -7530,7 +7530,7 @@ virDomainChrSourceDefParseXML(virDomainChrSourceDefPtr def,
break;
}
cleanup:
cleanup:
VIR_FREE(mode);
VIR_FREE(protocol);
VIR_FREE(bindHost);
@ -7542,7 +7542,7 @@ cleanup:
return remaining;
error:
error:
virDomainChrSourceDefClear(def);
remaining = -1;
goto cleanup;
@ -7678,12 +7678,12 @@ virDomainChrDefParseXML(xmlXPathContextPtr ctxt,
goto error;
}
cleanup:
cleanup:
VIR_FREE(type);
return def;
error:
error:
virDomainChrDefFree(def);
def = NULL;
goto cleanup;
@ -7804,13 +7804,13 @@ virDomainSmartcardDefParseXML(xmlNodePtr node,
goto error;
}
cleanup:
cleanup:
VIR_FREE(mode);
VIR_FREE(type);
return def;
error:
error:
virDomainSmartcardDefFree(def);
def = NULL;
goto cleanup;
@ -7900,7 +7900,7 @@ virDomainTPMDefParseXML(xmlNodePtr node,
if (virDomainDeviceInfoParseXML(node, NULL, &def->info, flags) < 0)
goto error;
cleanup:
cleanup:
VIR_FREE(type);
VIR_FREE(path);
VIR_FREE(model);
@ -7909,7 +7909,7 @@ cleanup:
ctxt->node = save;
return def;
error:
error:
virDomainTPMDefFree(def);
def = NULL;
goto cleanup;
@ -8004,13 +8004,13 @@ virDomainInputDefParseXML(const virDomainDef *dom,
goto error;
}
cleanup:
cleanup:
VIR_FREE(type);
VIR_FREE(bus);
return def;
error:
error:
virDomainInputDefFree(def);
def = NULL;
goto cleanup;
@ -8044,12 +8044,12 @@ virDomainHubDefParseXML(xmlNodePtr node, unsigned int flags)
if (virDomainDeviceInfoParseXML(node, NULL, &def->info, flags) < 0)
goto error;
cleanup:
cleanup:
VIR_FREE(type);
return def;
error:
error:
virDomainHubDefFree(def);
def = NULL;
goto cleanup;
@ -8172,7 +8172,7 @@ virDomainTimerDefParseXML(xmlNodePtr node,
}
}
cleanup:
cleanup:
VIR_FREE(name);
VIR_FREE(present);
VIR_FREE(tickpolicy);
@ -8182,7 +8182,7 @@ cleanup:
return def;
error:
error:
VIR_FREE(def);
goto cleanup;
}
@ -8319,7 +8319,7 @@ virDomainGraphicsListenDefParseXML(virDomainGraphicsListenDefPtr def,
}
ret = 0;
error:
error:
if (ret < 0)
virDomainGraphicsListenDefClear(def);
VIR_FREE(type);
@ -8862,7 +8862,7 @@ virDomainGraphicsDefParseXML(xmlNodePtr node,
}
}
cleanup:
cleanup:
VIR_FREE(type);
VIR_FREE(listenNodes);
VIR_FREE(listenAddr);
@ -8870,7 +8870,7 @@ cleanup:
ctxt->node = save;
return def;
error:
error:
virDomainGraphicsDefFree(def);
def = NULL;
goto cleanup;
@ -8893,12 +8893,12 @@ virDomainSoundCodecDefParseXML(xmlNodePtr node)
goto error;
}
cleanup:
cleanup:
VIR_FREE(type);
return def;
error:
error:
virDomainSoundCodecDefFree(def);
def = NULL;
goto cleanup;
@ -8961,13 +8961,13 @@ virDomainSoundDefParseXML(xmlNodePtr node,
if (virDomainDeviceInfoParseXML(node, NULL, &def->info, flags) < 0)
goto error;
cleanup:
cleanup:
VIR_FREE(model);
ctxt->node = save;
return def;
error:
error:
virDomainSoundDefFree(def);
def = NULL;
goto cleanup;
@ -9014,13 +9014,13 @@ virDomainWatchdogDefParseXML(xmlNodePtr node,
if (virDomainDeviceInfoParseXML(node, NULL, &def->info, flags) < 0)
goto error;
cleanup:
cleanup:
VIR_FREE(action);
VIR_FREE(model);
return def;
error:
error:
virDomainWatchdogDefFree(def);
def = NULL;
goto cleanup;
@ -9133,7 +9133,7 @@ virDomainRNGDefParseXML(xmlNodePtr node,
if (virDomainDeviceInfoParseXML(node, NULL, &def->info, flags) < 0)
goto error;
cleanup:
cleanup:
VIR_FREE(model);
VIR_FREE(backend);
VIR_FREE(type);
@ -9141,7 +9141,7 @@ cleanup:
ctxt->node = save;
return def;
error:
error:
virDomainRNGDefFree(def);
def = NULL;
goto cleanup;
@ -9183,13 +9183,13 @@ virDomainMemballoonDefParseXML(xmlNodePtr node,
if (virDomainDeviceInfoParseXML(node, NULL, &def->info, flags) < 0)
goto error;
cleanup:
cleanup:
VIR_FREE(model);
ctxt->node = save;
return def;
error:
error:
virDomainMemballoonDefFree(def);
def = NULL;
goto cleanup;
@ -9209,7 +9209,7 @@ virDomainNVRAMDefParseXML(xmlNodePtr node,
return def;
error:
error:
virDomainNVRAMDefFree(def);
return NULL;
}
@ -9320,12 +9320,12 @@ virSysinfoParseXML(xmlNodePtr node,
def->system_family =
virXPathString("string(system/entry[@name='family'])", ctxt);
cleanup:
cleanup:
VIR_FREE(type);
VIR_FREE(tmpUUID);
return def;
error:
error:
virSysinfoDefFree(def);
def = NULL;
goto cleanup;
@ -9533,7 +9533,7 @@ virDomainVideoDefParseXML(xmlNodePtr node,
return def;
error:
error:
virDomainVideoDefFree(def);
VIR_FREE(type);
VIR_FREE(ram);
@ -9621,13 +9621,13 @@ virDomainHostdevDefParseXML(virDomainXMLOptionPtr xmlopt,
}
}
cleanup:
cleanup:
VIR_FREE(type);
VIR_FREE(mode);
ctxt->node = save;
return def;
error:
error:
virDomainHostdevDefFree(def);
def = NULL;
goto cleanup;
@ -9697,12 +9697,12 @@ virDomainRedirdevDefParseXML(xmlNodePtr node,
}
cleanup:
cleanup:
VIR_FREE(bus);
VIR_FREE(type);
return def;
error:
error:
virDomainRedirdevDefFree(def);
def = NULL;
goto cleanup;
@ -9766,7 +9766,7 @@ virDomainRedirFilterUsbVersionHelper(const char *version,
def->version = hex;
ret = 0;
cleanup:
cleanup:
VIR_FREE(version_copy);
return ret;
}
@ -9848,7 +9848,7 @@ virDomainRedirFilterUsbDevDefParseXML(xmlNodePtr node)
goto error;
}
cleanup:
cleanup:
VIR_FREE(class);
VIR_FREE(vendor);
VIR_FREE(product);
@ -9856,7 +9856,7 @@ cleanup:
VIR_FREE(allow);
return def;
error:
error:
VIR_FREE(def);
def = NULL;
goto cleanup;
@ -9896,7 +9896,7 @@ virDomainRedirFilterDefParseXML(xmlNodePtr node,
ctxt->node = save;
return def;
error:
error:
VIR_FREE(nodes);
virDomainRedirFilterDefFree(def);
return NULL;
@ -10079,12 +10079,12 @@ virDomainDeviceDefParse(const char *xmlStr,
if (virDomainDeviceDefPostParse(dev, def, caps, xmlopt) < 0)
goto error;
cleanup:
cleanup:
xmlFreeDoc(xml);
xmlXPathFreeContext(ctxt);
return dev;
error:
error:
VIR_FREE(dev);
goto cleanup;
}
@ -10924,7 +10924,7 @@ virDomainDefParseBootXML(xmlXPathContextPtr ctxt,
ret = 0;
cleanup:
cleanup:
VIR_FREE(tmp);
VIR_FREE(nodes);
return ret;
@ -10984,7 +10984,7 @@ virDomainIdmapDefParseXML(xmlXPathContextPtr ctxt,
goto cleanup;
}
cleanup:
cleanup:
ctxt->node = save_ctxt;
return idmap;
}
@ -11001,7 +11001,7 @@ virDomainPanicDefParseXML(xmlNodePtr node)
goto error;
return panic;
error:
error:
virDomainPanicDefFree(panic);
return NULL;
}
@ -11075,11 +11075,11 @@ virDomainVcpuPinDefParseXML(xmlNodePtr node,
goto error;
}
cleanup:
cleanup:
ctxt->node = oldnode;
return def;
error:
error:
VIR_FREE(def);
goto cleanup;
}
@ -11195,7 +11195,7 @@ virDomainParseMemory(const char *xpath, xmlXPathContextPtr ctxt,
/* Yes, we really do use kibibytes for our internal sizing. */
*mem = VIR_DIV_UP(bytes, 1024);
ret = 0;
cleanup:
cleanup:
return ret;
}
@ -11222,7 +11222,7 @@ virDomainResourceDefParse(xmlNodePtr node,
ctxt->node = tmp;
return def;
error:
error:
ctxt->node = tmp;
virDomainResourceDefFree(def);
return NULL;
@ -12989,7 +12989,7 @@ virDomainDefParseXML(xmlDocPtr xml,
return def;
error:
error:
VIR_FREE(tmp);
VIR_FREE(nodes);
virHashFree(bootHash);
@ -13091,7 +13091,7 @@ virDomainObjParseXML(xmlDocPtr xml,
return obj;
error:
error:
virObjectUnref(obj);
VIR_FREE(nodes);
return NULL;
@ -13172,7 +13172,7 @@ virDomainDefParseNode(xmlDocPtr xml,
def = virDomainDefParseXML(xml, root, ctxt, caps, xmlopt,
expectedVirtTypes, flags);
cleanup:
cleanup:
xmlXPathFreeContext(ctxt);
return def;
}
@ -13205,7 +13205,7 @@ virDomainObjParseNode(xmlDocPtr xml,
ctxt->node = root;
obj = virDomainObjParseXML(xml, ctxt, caps, xmlopt, expectedVirtTypes, flags);
cleanup:
cleanup:
xmlXPathFreeContext(ctxt);
return obj;
}
@ -14346,7 +14346,7 @@ virDomainDefCheckABIStability(virDomainDefPtr src,
return true;
error:
error:
err = virSaveLastError();
strSrc = virDomainDefFormat(src, 0);
@ -14591,7 +14591,7 @@ virDomainVcpuPinAdd(virDomainVcpuPinDefPtr **vcpupin_list,
return 0;
error:
error:
virDomainVcpuPinDefFree(vcpupin);
return -1;
}
@ -17915,9 +17915,9 @@ virDomainObjFormat(virDomainXMLOptionPtr xmlopt,
return virBufferContentAndReset(&buf);
no_memory:
no_memory:
virReportOOMError();
error:
error:
virBufferFreeAndReset(&buf);
return NULL;
}
@ -18052,7 +18052,7 @@ virDomainSaveConfig(const char *configDir,
goto cleanup;
ret = 0;
cleanup:
cleanup:
VIR_FREE(xml);
return ret;
}
@ -18078,7 +18078,7 @@ virDomainSaveStatus(virDomainXMLOptionPtr xmlopt,
goto cleanup;
ret = 0;
cleanup:
cleanup:
VIR_FREE(xml);
return ret;
}
@ -18127,7 +18127,7 @@ virDomainObjListLoadConfig(virDomainObjListPtr doms,
VIR_FREE(autostartLink);
return dom;
error:
error:
VIR_FREE(configFile);
VIR_FREE(autostartLink);
virDomainDefFree(def);
@ -18176,7 +18176,7 @@ virDomainObjListLoadStatus(virDomainObjListPtr doms,
VIR_FREE(statusFile);
return obj;
error:
error:
virObjectUnref(obj);
VIR_FREE(statusFile);
return NULL;
@ -18279,7 +18279,7 @@ virDomainDeleteConfig(const char *configDir,
ret = 0;
cleanup:
cleanup:
VIR_FREE(configFile);
VIR_FREE(autostartLink);
return ret;
@ -18392,7 +18392,7 @@ virDomainObjListCount(void *payload,
if (!data->active)
data->count++;
}
cleanup:
cleanup:
virObjectUnlock(obj);
}
@ -18430,7 +18430,7 @@ virDomainObjListCopyActiveIDs(void *payload,
goto cleanup;
if (virDomainObjIsActive(obj) && data->numids < data->maxids)
data->ids[data->numids++] = obj->def->id;
cleanup:
cleanup:
virObjectUnlock(obj);
}
@ -18479,7 +18479,7 @@ virDomainObjListCopyInactiveNames(void *payload,
else
data->numnames++;
}
cleanup:
cleanup:
virObjectUnlock(obj);
}
@ -18587,7 +18587,7 @@ virDomainChrDefForeach(virDomainDefPtr def,
goto done;
}
done:
done:
return rc;
}
@ -18611,7 +18611,7 @@ virDomainSmartcardDefForeach(virDomainDefPtr def,
goto done;
}
done:
done:
return rc;
}
@ -18657,7 +18657,7 @@ virDomainDiskDefForeachPath(virDomainDiskDefPtr disk,
ret = 0;
cleanup:
cleanup:
return ret;
}
@ -19214,7 +19214,7 @@ virDomainDeviceDefCopy(virDomainDeviceDefPtr src,
xmlStr = virBufferContentAndReset(&buf);
ret = virDomainDeviceDefParse(xmlStr, def, caps, xmlopt, flags);
cleanup:
cleanup:
VIR_FREE(xmlStr);
return ret;
}
@ -19318,7 +19318,7 @@ virDomainListPopulate(void *payload,
data->domains[data->ndomains++] = dom;
cleanup:
cleanup:
virObjectUnlock(vm);
return;
}
@ -19359,7 +19359,7 @@ virDomainObjListExport(virDomainObjListPtr doms,
ret = data.ndomains;
cleanup:
cleanup:
if (data.domains) {
int count = virHashSize(doms->objs);
for (i = 0; i < count; i++)
@ -19586,7 +19586,7 @@ virDomainObjGetMetadata(virDomainObjPtr vm,
virReportError(VIR_ERR_NO_DOMAIN_METADATA, "%s",
_("Requested metadata element is not present"));
cleanup:
cleanup:
return ret;
}
@ -19666,7 +19666,7 @@ virDomainDefSetMetadata(virDomainDefPtr def,
ret = 0;
cleanup:
cleanup:
xmlFreeDoc(doc);
return ret;
}

View File

@ -886,7 +886,7 @@ virDomainEventDiskChangeNew(int id,
return (virObjectEventPtr)ev;
error:
error:
virObjectUnref(ev);
return NULL;
}
@ -939,7 +939,7 @@ virDomainEventTrayChangeNew(int id,
return (virObjectEventPtr)ev;
error:
error:
virObjectUnref(ev);
return NULL;
}
@ -1129,7 +1129,7 @@ virDomainEventDeviceRemovedNew(int id,
return (virObjectEventPtr)ev;
error:
error:
virObjectUnref(ev);
return NULL;
}
@ -1346,7 +1346,7 @@ virDomainEventDispatchDefaultFunc(virConnectPtr conn,
VIR_WARN("Unexpected event ID %d", event->eventID);
cleanup:
cleanup:
virDomainFree(dom);
}
@ -1380,7 +1380,7 @@ virDomainQemuMonitorEventNew(int id,
return (virObjectEventPtr)ev;
error:
error:
virObjectUnref(ev);
return NULL;
}

View File

@ -350,7 +350,7 @@ virInterfaceDefParseProtoIPv4(virInterfaceProtocolDefPtr def,
ret = 0;
error:
error:
VIR_FREE(ipNodes);
return ret;
}
@ -405,7 +405,7 @@ virInterfaceDefParseProtoIPv6(virInterfaceProtocolDefPtr def,
ret = 0;
error:
error:
VIR_FREE(ipNodes);
return ret;
}
@ -473,7 +473,7 @@ virInterfaceDefParseIfAdressing(virInterfaceDefPtr def,
ret = 0;
error:
error:
VIR_FREE(protoNodes);
ctxt->node = save;
return ret;
@ -516,7 +516,7 @@ virInterfaceDefParseBridge(virInterfaceDefPtr def,
}
}
error:
error:
VIR_FREE(interfaces);
ctxt->node = bridge;
return ret;
@ -563,7 +563,7 @@ virInterfaceDefParseBondItfs(virInterfaceDefPtr def,
def->data.bond.itf[i] = itf;
}
error:
error:
VIR_FREE(interfaces);
ctxt->node = bond;
return ret;
@ -814,7 +814,7 @@ virInterfaceDefParseXML(xmlXPathContextPtr ctxt, int parentIfType)
ctxt->node = cur;
return def;
error:
error:
ctxt->node = cur;
virInterfaceDefFree(def);
return NULL;
@ -843,7 +843,7 @@ virInterfaceDefPtr virInterfaceDefParseNode(xmlDocPtr xml,
ctxt->node = root;
def = virInterfaceDefParseXML(ctxt, VIR_INTERFACE_TYPE_LAST);
cleanup:
cleanup:
xmlXPathFreeContext(ctxt);
return def;
}
@ -1123,9 +1123,9 @@ virInterfaceDefDevFormat(virBufferPtr buf, const virInterfaceDef *def)
if (virBufferError(buf))
goto no_memory;
return 0;
no_memory:
no_memory:
virReportOOMError();
cleanup:
cleanup:
return -1;
}
@ -1248,7 +1248,7 @@ int virInterfaceObjListClone(virInterfaceObjListPtr src,
}
ret = cnt;
cleanup:
cleanup:
if ((ret < 0) && dest)
virInterfaceObjListFree(dest);
return ret;

View File

@ -92,7 +92,7 @@ virNetDevBandwidthParseRate(xmlNodePtr node, virNetDevBandwidthRatePtr rate)
ret = 0;
cleanup:
cleanup:
VIR_FREE(average);
VIR_FREE(peak);
VIR_FREE(burst);
@ -198,7 +198,7 @@ virNetDevBandwidthParse(xmlNodePtr node,
return def;
error:
error:
virNetDevBandwidthFree(def);
return NULL;
}
@ -266,6 +266,6 @@ virNetDevBandwidthFormat(virNetDevBandwidthPtr def, virBufferPtr buf)
ret = 0;
cleanup:
cleanup:
return ret;
}

View File

@ -129,7 +129,7 @@ virNetDevVlanParse(xmlNodePtr node, xmlXPathContextPtr ctxt, virNetDevVlanPtr de
}
ret = 0;
cleanup:
cleanup:
ctxt->node = save;
VIR_FREE(tagNodes);
VIR_FREE(trunk);

View File

@ -183,7 +183,7 @@ virNetDevVPortProfileParse(xmlNodePtr node, unsigned int flags)
if (virNetDevVPortProfileCheckNoExtras(virtPort) < 0)
goto error;
cleanup:
cleanup:
VIR_FREE(virtPortManagerID);
VIR_FREE(virtPortTypeID);
VIR_FREE(virtPortTypeIDVersion);
@ -194,7 +194,7 @@ cleanup:
return virtPort;
error:
error:
VIR_FREE(virtPort);
goto cleanup;
}

View File

@ -394,7 +394,7 @@ virNetworkAssignDef(virNetworkObjListPtr nets,
network->def = def;
return network;
error:
error:
virNetworkObjUnlock(network);
virNetworkObjFree(network);
return NULL;
@ -510,7 +510,7 @@ virNetworkDefCopy(virNetworkDefPtr def, unsigned int flags)
if (!(xml = virNetworkDefFormat(def, flags)))
goto cleanup;
newDef = virNetworkDefParseString(xml);
cleanup:
cleanup:
VIR_FREE(xml);
return newDef;
}
@ -555,7 +555,7 @@ virNetworkConfigChangeSetup(virNetworkObjPtr network, unsigned int flags)
}
ret = 0;
cleanup:
cleanup:
return ret;
}
@ -668,7 +668,7 @@ virSocketAddrRangeParseXML(const char *networkName,
ret = 0;
cleanup:
cleanup:
VIR_FREE(start);
VIR_FREE(end);
return ret;
@ -784,7 +784,7 @@ virNetworkDHCPHostDefParseXML(const char *networkName,
host->ip = inaddr;
ret = 0;
cleanup:
cleanup:
VIR_FREE(mac);
VIR_FREE(id);
VIR_FREE(name);
@ -919,7 +919,7 @@ virNetworkDNSHostDefParseXML(const char *networkName,
return 0;
error:
error:
virNetworkDNSHostDefClear(def);
return -1;
}
@ -1003,7 +1003,7 @@ virNetworkDNSSrvDefParseXML(const char *networkName,
}
return 0;
error:
error:
virNetworkDNSSrvDefClear(def);
return -1;
}
@ -1041,7 +1041,7 @@ virNetworkDNSTxtDefParseXML(const char *networkName,
}
return 0;
error:
error:
virNetworkDNSTxtDefClear(def);
return -1;
}
@ -1162,7 +1162,7 @@ virNetworkDNSDefParseXML(const char *networkName,
}
ret = 0;
cleanup:
cleanup:
VIR_FREE(forwardPlainNames);
VIR_FREE(fwdNodes);
VIR_FREE(hostNodes);
@ -1312,7 +1312,7 @@ virNetworkIPDefParseXML(const char *networkName,
result = 0;
cleanup:
cleanup:
if (result < 0) {
virNetworkIpDefClear(def);
}
@ -1538,7 +1538,7 @@ virNetworkRouteDefParseXML(const char *networkName,
result = 0;
cleanup:
cleanup:
if (result < 0) {
virNetworkRouteDefClear(def);
}
@ -1599,7 +1599,7 @@ virNetworkPortGroupParseXML(virPortGroupDefPtr def,
goto cleanup;
result = 0;
cleanup:
cleanup:
if (result < 0) {
virPortGroupDefClear(def);
}
@ -1707,7 +1707,7 @@ virNetworkForwardNatDefParseXML(const char *networkName,
}
ret = 0;
cleanup:
cleanup:
VIR_FREE(addrStart);
VIR_FREE(addrEnd);
VIR_FREE(natAddrNodes);
@ -1936,7 +1936,7 @@ virNetworkForwardDefParseXML(const char *networkName,
}
ret = 0;
cleanup:
cleanup:
VIR_FREE(type);
VIR_FREE(forwardDev);
VIR_FREE(forwardManaged);
@ -2238,7 +2238,7 @@ virNetworkDefParseXML(xmlXPathContextPtr ctxt)
ctxt->node = save;
return def;
error:
error:
VIR_FREE(routeNodes);
VIR_FREE(stp);
virNetworkDefFree(def);
@ -2298,7 +2298,7 @@ virNetworkDefPtr virNetworkDefParseNode(xmlDocPtr xml,
ctxt->node = root;
def = virNetworkDefParseXML(ctxt);
cleanup:
cleanup:
xmlXPathFreeContext(ctxt);
return def;
}
@ -2479,7 +2479,7 @@ virNetworkIpDefFormat(virBufferPtr buf,
virBufferAddLit(buf, "</ip>\n");
result = 0;
error:
error:
return result;
}
@ -2526,7 +2526,7 @@ virNetworkRouteDefFormat(virBufferPtr buf,
virBufferAddLit(buf, "/>\n");
result = 0;
error:
error:
return result;
}
@ -2594,7 +2594,7 @@ virNetworkForwardNatDefFormat(virBufferPtr buf,
virBufferAddLit(buf, "</nat>\n");
ret = 0;
cleanup:
cleanup:
VIR_FREE(addrStart);
VIR_FREE(addrEnd);
return ret;
@ -2760,7 +2760,7 @@ virNetworkDefFormatBuf(virBufferPtr buf,
return 0;
error:
error:
return -1;
}
@ -2778,9 +2778,9 @@ virNetworkDefFormat(const virNetworkDef *def,
return virBufferContentAndReset(&buf);
no_memory:
no_memory:
virReportOOMError();
error:
error:
virBufferFreeAndReset(&buf);
return NULL;
}
@ -2819,9 +2819,9 @@ virNetworkObjFormat(virNetworkObjPtr net,
return virBufferContentAndReset(&buf);
no_memory:
no_memory:
virReportOOMError();
error:
error:
virBufferFreeAndReset(&buf);
return NULL;
}
@ -2883,7 +2883,7 @@ int virNetworkSaveConfig(const char *configDir,
goto cleanup;
ret = 0;
cleanup:
cleanup:
VIR_FREE(xml);
return ret;
}
@ -2903,7 +2903,7 @@ int virNetworkSaveStatus(const char *statusDir,
goto cleanup;
ret = 0;
cleanup:
cleanup:
VIR_FREE(xml);
return ret;
}
@ -3018,13 +3018,13 @@ virNetworkLoadState(virNetworkObjListPtr nets,
net->taint = taint;
cleanup:
cleanup:
VIR_FREE(configFile);
xmlFreeDoc(xml);
xmlXPathFreeContext(ctxt);
return net;
error:
error:
VIR_FREE(nodes);
virBitmapFree(class_id_map);
virNetworkDefFree(def);
@ -3082,7 +3082,7 @@ virNetworkObjPtr virNetworkLoadConfig(virNetworkObjListPtr nets,
return net;
error:
error:
VIR_FREE(configFile);
VIR_FREE(autostartLink);
virNetworkDefFree(def);
@ -3188,7 +3188,7 @@ int virNetworkDeleteConfig(const char *configDir,
ret = 0;
error:
error:
VIR_FREE(configFile);
VIR_FREE(autostartLink);
return ret;
@ -3273,7 +3273,7 @@ int virNetworkSetBridgeName(virNetworkObjListPtr nets,
}
ret = 0;
error:
error:
return ret;
}
@ -3513,7 +3513,7 @@ virNetworkDefUpdateIPDHCPHost(virNetworkDefPtr def,
}
ret = 0;
cleanup:
cleanup:
virNetworkDHCPHostDefClear(&host);
return ret;
}
@ -3602,7 +3602,7 @@ virNetworkDefUpdateIPDHCPRange(virNetworkDefPtr def,
}
ret = 0;
cleanup:
cleanup:
return ret;
}
@ -3707,7 +3707,7 @@ virNetworkDefUpdateForwardInterface(virNetworkDefPtr def,
}
ret = 0;
cleanup:
cleanup:
virNetworkForwardIfDefClear(&iface);
return ret;
}
@ -3813,7 +3813,7 @@ virNetworkDefUpdatePortGroup(virNetworkDefPtr def,
}
ret = 0;
cleanup:
cleanup:
virPortGroupDefClear(&portgroup);
return ret;
}
@ -3907,7 +3907,7 @@ virNetworkDefUpdateDNSHost(virNetworkDefPtr def,
}
ret = 0;
cleanup:
cleanup:
virNetworkDNSHostDefClear(&host);
return ret;
}
@ -3993,7 +3993,7 @@ virNetworkDefUpdateDNSSrv(virNetworkDefPtr def,
}
ret = 0;
cleanup:
cleanup:
virNetworkDNSSrvDefClear(&srv);
return ret;
}
@ -4066,7 +4066,7 @@ virNetworkDefUpdateDNSTxt(virNetworkDefPtr def,
}
ret = 0;
cleanup:
cleanup:
virNetworkDNSTxtDefClear(&txt);
return ret;
}
@ -4137,7 +4137,7 @@ virNetworkDefUpdateSection(virNetworkDefPtr def,
break;
}
cleanup:
cleanup:
xmlFreeDoc(doc);
xmlXPathFreeContext(ctxt);
return ret;
@ -4223,7 +4223,7 @@ virNetworkObjUpdate(virNetworkObjPtr network,
}
ret = 0;
cleanup:
cleanup:
virNetworkDefFree(livedef);
virNetworkDefFree(configdef);
return ret;
@ -4285,7 +4285,7 @@ virNetworkObjIsDuplicate(virNetworkObjListPtr doms,
ret = 0;
}
cleanup:
cleanup:
if (vm)
virNetworkObjUnlock(vm);
return ret;
@ -4379,7 +4379,7 @@ virNetworkObjListExport(virConnectPtr conn,
ret = nnets;
cleanup:
cleanup:
if (tmp_nets) {
for (i = 0; i < nnets; i++) {
if (tmp_nets[i])

View File

@ -118,7 +118,7 @@ virNetworkEventDispatchDefaultFunc(virConnectPtr conn,
}
VIR_WARN("Unexpected event ID %d", event->eventID);
cleanup:
cleanup:
virNetworkFree(net);
}

View File

@ -655,7 +655,7 @@ virNodeDevCapStorageParseXML(xmlXPathContextPtr ctxt,
}
ret = 0;
out:
out:
VIR_FREE(nodes);
ctxt->node = orignode;
return ret;
@ -700,7 +700,7 @@ virNodeDevCapScsiParseXML(xmlXPathContextPtr ctxt,
data->scsi.type = virXPathString("string(./type[1])", ctxt);
ret = 0;
out:
out:
ctxt->node = orignode;
return ret;
}
@ -728,7 +728,7 @@ virNodeDevCapScsiTargetParseXML(xmlXPathContextPtr ctxt,
ret = 0;
out:
out:
ctxt->node = orignode;
return ret;
}
@ -823,7 +823,7 @@ virNodeDevCapScsiHostParseXML(xmlXPathContextPtr ctxt,
ret = 0;
out:
out:
VIR_FREE(type);
ctxt->node = orignode;
VIR_FREE(nodes);
@ -870,7 +870,7 @@ virNodeDevCapNetParseXML(xmlXPathContextPtr ctxt,
}
ret = 0;
out:
out:
ctxt->node = orignode;
return ret;
}
@ -914,7 +914,7 @@ virNodeDevCapUsbInterfaceParseXML(xmlXPathContextPtr ctxt,
data->usb_if.description = virXPathString("string(./description[1])", ctxt);
ret = 0;
out:
out:
ctxt->node = orignode;
return ret;
}
@ -982,7 +982,7 @@ virNodeDevCapUsbDevParseXML(xmlXPathContextPtr ctxt,
data->usb_dev.product_name = virXPathString("string(./product[1])", ctxt);
ret = 0;
out:
out:
ctxt->node = orignode;
return ret;
}
@ -1035,7 +1035,7 @@ virNodeDevCapPciDevIommuGroupParseXML(xmlXPathContextPtr ctxt,
}
ret = 0;
cleanup:
cleanup:
ctxt->node = origNode;
VIR_FREE(numberStr);
VIR_FREE(addrNodes);
@ -1102,7 +1102,7 @@ virNodeDevCapPciDevParseXML(xmlXPathContextPtr ctxt,
}
}
ret = 0;
out:
out:
ctxt->node = orignode;
return ret;
}
@ -1146,7 +1146,7 @@ virNodeDevCapSystemParseXML(xmlXPathContextPtr ctxt,
data->system.firmware.release_date = virXPathString("string(./firmware/release_date[1])", ctxt);
ret = 0;
out:
out:
ctxt->node = orignode;
return ret;
}
@ -1224,7 +1224,7 @@ virNodeDevCapsDefParseXML(xmlXPathContextPtr ctxt,
goto error;
return caps;
error:
error:
virNodeDevCapsDefFree(caps);
return NULL;
}
@ -1320,7 +1320,7 @@ virNodeDeviceDefParseNode(xmlDocPtr xml,
ctxt->node = root;
def = virNodeDeviceDefParseXML(ctxt, create, virt_type);
cleanup:
cleanup:
xmlXPathFreeContext(ctxt);
return def;
}
@ -1393,7 +1393,7 @@ virNodeDeviceGetWWNs(virNodeDeviceDefPtr def,
}
ret = 0;
cleanup:
cleanup:
return ret;
}
@ -1441,7 +1441,7 @@ virNodeDeviceGetParentHost(virNodeDeviceObjListPtr devs,
virNodeDeviceObjUnlock(parent);
out:
out:
return ret;
}
@ -1636,7 +1636,7 @@ virNodeDeviceObjListExport(virConnectPtr conn,
ret = ndevices;
cleanup:
cleanup:
if (tmp_devices) {
for (i = 0; i < ndevices; i++) {
if (tmp_devices[i])

View File

@ -1006,7 +1006,7 @@ ipsetValidator(enum attrDatatype datatype ATTRIBUTE_UNUSED, union data *val,
return true;
arg_err_exit:
arg_err_exit:
virReportError(VIR_ERR_INVALID_ARG,
"%s", errmsg);
return false;
@ -1052,7 +1052,7 @@ ipsetFlagsValidator(enum attrDatatype datatype ATTRIBUTE_UNUSED, union data *val
return true;
arg_err_exit:
arg_err_exit:
virReportError(VIR_ERR_INVALID_ARG,
"%s", errmsg);
return false;
@ -2070,10 +2070,10 @@ virNWFilterIncludeParse(xmlNodePtr cur)
if (!ret->params)
goto err_exit;
cleanup:
cleanup:
return ret;
err_exit:
err_exit:
virNWFilterIncludeDefFree(ret);
ret = NULL;
goto cleanup;
@ -2405,7 +2405,7 @@ virNWFilterRuleParse(xmlNodePtr node)
virNWFilterRuleDefFixup(ret);
cleanup:
cleanup:
VIR_FREE(prio);
VIR_FREE(action);
VIR_FREE(direction);
@ -2413,7 +2413,7 @@ cleanup:
return ret;
err_exit:
err_exit:
virNWFilterRuleDefFree(ret);
ret = NULL;
goto cleanup;
@ -2495,7 +2495,7 @@ virNWFilterIsAllowedChain(const char *chainname)
virReportError(VIR_ERR_INVALID_ARG, "%s", msg);
VIR_FREE(msg);
err_exit:
err_exit:
return NULL;
}
@ -2651,7 +2651,7 @@ virNWFilterDefParseNode(xmlDocPtr xml,
ctxt->node = root;
def = virNWFilterDefParseXML(ctxt);
cleanup:
cleanup:
xmlXPathFreeContext(ctxt);
return def;
}
@ -2762,7 +2762,7 @@ int virNWFilterSaveConfig(const char *configDir,
goto cleanup;
ret = 0;
cleanup:
cleanup:
VIR_FREE(xml);
return ret;
}
@ -2971,7 +2971,7 @@ virNWFilterDefEqual(const virNWFilterDef *def1, virNWFilterDefPtr def2,
ret = STREQ(xml1, xml2);
cleanup:
cleanup:
if (!cmpUUIDs)
memcpy(def2->uuid, rem_uuid, sizeof(rem_uuid));
@ -3339,7 +3339,7 @@ virNWFilterRuleDefDetailsFormat(virBufferPtr buf,
virBufferAsprintf(buf,
"<%s/>\n", type);
err_exit:
err_exit:
return;
}

View File

@ -69,7 +69,7 @@ virNWFilterIPAddrMapAddIPAddr(const char *ifname, char *addr)
ret = 0;
cleanup:
cleanup:
virMutexUnlock(&ipAddressMapLock);
return ret;
@ -108,7 +108,7 @@ virNWFilterIPAddrMapDelIPAddr(const char *ifname, const char *ipaddr)
ret = virNWFilterVarValueGetCardinality(val);
}
} else {
remove_entry:
remove_entry:
/* remove whole entry */
val = virNWFilterHashTableRemoveEntry(ipAddressMap, ifname);
virNWFilterVarValueFree(val);

View File

@ -97,7 +97,7 @@ virNWFilterVarValueCopy(const virNWFilterVarValue *val)
return res;
err_exit:
err_exit:
virNWFilterVarValueFree(res);
return NULL;
}
@ -505,7 +505,7 @@ virNWFilterVarCombIterCreate(virNWFilterHashTablePtr hash,
return res;
err_exit:
err_exit:
virNWFilterVarCombIterFree(res);
return NULL;
}
@ -516,7 +516,7 @@ virNWFilterVarCombIterNext(virNWFilterVarCombIterPtr ci)
size_t i;
for (i = 0; i < ci->nIter; i++) {
next:
next:
ci->iter[i].curValue++;
if (ci->iter[i].curValue <= ci->iter[i].maxValue) {
if (!virNWFilterVarCombIterEntryAreUniqueEntries(
@ -766,7 +766,7 @@ virNWFilterHashTablePutAll(virNWFilterHashTablePtr src,
return 0;
err_exit:
err_exit:
return -1;
}
@ -851,7 +851,7 @@ virNWFilterParseParamAttributes(xmlNodePtr cur)
}
value = NULL;
}
skip_entry:
skip_entry:
virNWFilterVarValueFree(value);
VIR_FREE(nam);
VIR_FREE(val);
@ -861,7 +861,7 @@ skip_entry:
}
return table;
err_exit:
err_exit:
VIR_FREE(nam);
VIR_FREE(val);
virNWFilterVarValueFree(value);
@ -1049,7 +1049,7 @@ virNWFilterVarAccessParse(const char *varAccess)
_("Malformatted variable"));
}
err_exit:
err_exit:
virNWFilterVarAccessFree(dest);
return NULL;

View File

@ -439,7 +439,7 @@ virObjectEventCallbackListAddID(virConnectPtr conn,
ret++;
}
cleanup:
cleanup:
if (event)
virObjectUnref(event->conn);
VIR_FREE(event);
@ -593,7 +593,7 @@ virObjectEventStateNew(void)
return state;
error:
error:
virObjectEventStateFree(state);
return NULL;
}
@ -902,7 +902,7 @@ virObjectEventStateRegisterID(virConnectPtr conn,
state->timer = -1;
}
cleanup:
cleanup:
virObjectEventStateUnlock(state);
return ret;
}

View File

@ -183,7 +183,7 @@ virDomainSnapshotDiskDefParseXML(xmlNodePtr node,
def->snapshot = VIR_DOMAIN_SNAPSHOT_LOCATION_EXTERNAL;
ret = 0;
cleanup:
cleanup:
VIR_FREE(snapshot);
VIR_FREE(type);
if (ret < 0)
@ -357,7 +357,7 @@ virDomainSnapshotDefParse(xmlXPathContextPtr ctxt,
ret = def;
cleanup:
cleanup:
VIR_FREE(creation);
VIR_FREE(state);
VIR_FREE(nodes);
@ -394,7 +394,7 @@ virDomainSnapshotDefParseNode(xmlDocPtr xml,
ctxt->node = root;
def = virDomainSnapshotDefParse(ctxt, caps, xmlopt,
expectedVirtTypes, flags);
cleanup:
cleanup:
xmlXPathFreeContext(ctxt);
return def;
}
@ -606,7 +606,7 @@ virDomainSnapshotAlignDisks(virDomainSnapshotDefPtr def,
ret = 0;
cleanup:
cleanup:
virBitmapFree(map);
return ret;
}
@ -1120,7 +1120,7 @@ virDomainListSnapshots(virDomainSnapshotObjListPtr snapshots,
ret = count;
*snaps = list;
cleanup:
cleanup:
for (i = 0; i < count; i++)
VIR_FREE(names[i]);
VIR_FREE(names);
@ -1301,7 +1301,7 @@ virDomainSnapshotRedefinePrep(virDomainPtr domain,
}
ret = 0;
cleanup:
cleanup:
return ret;
}

View File

@ -501,7 +501,7 @@ virStoragePoolDefParseAuthSecret(xmlXPathContextPtr ctxt,
}
ret = 0;
cleanup:
cleanup:
VIR_FREE(uuid);
return ret;
}
@ -553,7 +553,7 @@ virStoragePoolDefParseAuth(xmlXPathContextPtr ctxt,
ret = 0;
cleanup:
cleanup:
VIR_FREE(authType);
VIR_FREE(username);
return ret;
@ -720,7 +720,7 @@ virStoragePoolDefParseSource(xmlXPathContextPtr ctxt,
source->product = virXPathString("string(./product/@name)", ctxt);
ret = 0;
cleanup:
cleanup:
ctxt->node = relnode;
VIR_FREE(port);
@ -758,7 +758,7 @@ virStoragePoolDefParseSourceString(const char *srcSpec,
ret = def;
def = NULL;
cleanup:
cleanup:
virStoragePoolSourceFree(def);
xmlFreeDoc(doc);
xmlXPathFreeContext(xpath_ctxt);
@ -838,7 +838,7 @@ virStorageDefParsePerms(xmlXPathContextPtr ctxt,
perms->label = virXPathString("string(./label)", ctxt);
ret = 0;
error:
error:
ctxt->node = relnode;
return ret;
}
@ -992,13 +992,13 @@ virStoragePoolDefParseXML(xmlXPathContextPtr ctxt)
goto error;
}
cleanup:
cleanup:
VIR_FREE(uuid);
VIR_FREE(type);
VIR_FREE(target_path);
return ret;
error:
error:
virStoragePoolDefFree(ret);
ret = NULL;
goto cleanup;
@ -1027,7 +1027,7 @@ virStoragePoolDefParseNode(xmlDocPtr xml,
ctxt->node = root;
def = virStoragePoolDefParseXML(ctxt);
cleanup:
cleanup:
xmlXPathFreeContext(ctxt);
return def;
}
@ -1250,9 +1250,9 @@ virStoragePoolDefFormat(virStoragePoolDefPtr def)
return virBufferContentAndReset(&buf);
no_memory:
no_memory:
virReportOOMError();
cleanup:
cleanup:
virBufferFreeAndReset(&buf);
return NULL;
}
@ -1429,7 +1429,7 @@ virStorageVolDefParseXML(virStoragePoolDefPtr pool,
DEFAULT_VOL_PERM_MODE) < 0)
goto error;
cleanup:
cleanup:
VIR_FREE(nodes);
VIR_FREE(allocation);
VIR_FREE(capacity);
@ -1437,7 +1437,7 @@ cleanup:
VIR_FREE(type);
return ret;
error:
error:
virStorageVolDefFree(ret);
ret = NULL;
goto cleanup;
@ -1467,7 +1467,7 @@ virStorageVolDefParseNode(virStoragePoolDefPtr pool,
ctxt->node = root;
def = virStorageVolDefParseXML(pool, ctxt);
cleanup:
cleanup:
xmlXPathFreeContext(ctxt);
return def;
}
@ -1669,9 +1669,9 @@ virStorageVolDefFormat(virStoragePoolDefPtr pool,
return virBufferContentAndReset(&buf);
no_memory:
no_memory:
virReportOOMError();
cleanup:
cleanup:
virBufferFreeAndReset(&buf);
return NULL;
}
@ -2018,9 +2018,9 @@ virStoragePoolSourceListFormat(virStoragePoolSourceListPtr def)
return virBufferContentAndReset(&buf);
no_memory:
no_memory:
virReportOOMError();
cleanup:
cleanup:
virBufferFreeAndReset(&buf);
return NULL;
}
@ -2082,7 +2082,7 @@ virStoragePoolObjIsDuplicate(virStoragePoolObjListPtr pools,
ret = 0;
}
cleanup:
cleanup:
if (pool)
virStoragePoolObjUnlock(pool);
return ret;
@ -2291,7 +2291,7 @@ virStoragePoolObjListExport(virConnectPtr conn,
ret = npools;
cleanup:
cleanup:
if (tmp_pools) {
for (i = 0; i < npools; i++) {
if (tmp_pools[i])

View File

@ -117,7 +117,7 @@ virStorageEncryptionSecretParse(xmlXPathContextPtr ctxt,
ctxt->node = old_node;
return ret;
cleanup:
cleanup:
virStorageEncryptionSecretFree(ret);
VIR_FREE(uuidstr);
ctxt->node = old_node;
@ -169,7 +169,7 @@ virStorageEncryptionParseXML(xmlXPathContextPtr ctxt)
return ret;
cleanup:
cleanup:
VIR_FREE(nodes);
virStorageEncryptionFree(ret);
return NULL;
@ -197,7 +197,7 @@ virStorageEncryptionParseNode(xmlDocPtr xml, xmlNodePtr root)
ctxt->node = root;
enc = virStorageEncryptionParseXML(ctxt);
cleanup:
cleanup:
xmlXPathFreeContext(ctxt);
return enc;
}

View File

@ -96,7 +96,7 @@ static char *virChrdevLockFilePath(const char *dev)
sanitizedPath = virFileSanitizePath(path);
cleanup:
cleanup:
VIR_FREE(path);
VIR_FREE(devCopy);
@ -175,7 +175,7 @@ static int virChrdevLockFileCreate(const char *dev)
/* we hold the lock */
ret = 0;
cleanup:
cleanup:
VIR_FORCE_CLOSE(lockfd);
VIR_FREE(path);
VIR_FREE(pidStr);
@ -284,7 +284,7 @@ virChrdevsPtr virChrdevAlloc(void)
goto error;
return devs;
error:
error:
virChrdevFree(devs);
return NULL;
}
@ -433,7 +433,7 @@ int virChrdevOpen(virChrdevsPtr devs,
virMutexUnlock(&devs->lock);
return 0;
error:
error:
savedError = virSaveLastError();
if (added)