mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-02-22 11:22:23 +00:00
virCapabilitiesHostNUMAFormat: Swap order of arguments
The rest of virCapabilities format functions take virBuffer as the first argument and struct to format as the second. Also, they accept NULL (as the second argument). Fix virCapabilitiesHostNUMAFormat() so that it follows this logic. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> Reviewed-by: Ján Tomko <jtomko@redhat.com>
This commit is contained in:
parent
4ce1106277
commit
c2137a901c
@ -794,13 +794,16 @@ virCapabilitiesAddStoragePool(virCaps *caps,
|
||||
|
||||
|
||||
static int
|
||||
virCapabilitiesHostNUMAFormat(virCapsHostNUMA *caps,
|
||||
virBuffer *buf)
|
||||
virCapabilitiesHostNUMAFormat(virBuffer *buf,
|
||||
virCapsHostNUMA *caps)
|
||||
{
|
||||
size_t i;
|
||||
size_t j;
|
||||
char *siblings;
|
||||
|
||||
if (!caps)
|
||||
return 0;
|
||||
|
||||
virBufferAddLit(buf, "<topology>\n");
|
||||
virBufferAdjustIndent(buf, 2);
|
||||
virBufferAsprintf(buf, "<cells num='%d'>\n", caps->cells->len);
|
||||
@ -1125,8 +1128,7 @@ virCapabilitiesFormatHostXML(virCapsHost *host,
|
||||
virBufferAsprintf(buf, "<netprefix>%s</netprefix>\n",
|
||||
host->netprefix);
|
||||
|
||||
if (host->numa &&
|
||||
virCapabilitiesHostNUMAFormat(host->numa, buf) < 0)
|
||||
if (virCapabilitiesHostNUMAFormat(buf, host->numa) < 0)
|
||||
return -1;
|
||||
|
||||
if (virCapabilitiesFormatCaches(buf, &host->cache) < 0)
|
||||
|
Loading…
x
Reference in New Issue
Block a user