mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-12-22 13:45:38 +00:00
virCapabilitiesFormatCaches: free cpus_str right after use
This will simplify the cleanup when we start checking for buffer errors.
This commit is contained in:
parent
2074ef6cd4
commit
2403dcce51
@ -904,6 +904,7 @@ virCapabilitiesFormatCaches(virBufferPtr buf,
|
||||
bank->size >> (kilos * 10),
|
||||
kilos ? "KiB" : "B",
|
||||
cpus_str);
|
||||
VIR_FREE(cpus_str);
|
||||
|
||||
virBufferAdjustIndent(&controlBuf, indent + 4);
|
||||
for (j = 0; j < bank->ncontrols; j++) {
|
||||
@ -937,8 +938,6 @@ virCapabilitiesFormatCaches(virBufferPtr buf,
|
||||
} else {
|
||||
virBufferAddLit(buf, "/>\n");
|
||||
}
|
||||
|
||||
VIR_FREE(cpus_str);
|
||||
}
|
||||
|
||||
virBufferAdjustIndent(buf, -2);
|
||||
|
Loading…
Reference in New Issue
Block a user