conf: node_device: Add 'validate' argument to virNodeDeviceDefParse

Allow callers to request XML validation against the schema. All callers
for now pass 'false'.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Jonathon Jongsma <jjongsma@redhat.com>
This commit is contained in:
Peter Krempa
2022-10-18 12:34:07 +02:00
parent abfdaf8a94
commit 0268270b0f
7 changed files with 16 additions and 13 deletions

View File

@@ -71,7 +71,7 @@ testMdevctlCmd(virMdevctlCommand cmd_type,
}
if (!(def = virNodeDeviceDefParse(NULL, mdevxml, create, VIRT_TYPE,
&parser_callbacks, NULL)))
&parser_callbacks, NULL, false)))
return -1;
/* this function will set a stdin buffer containing the json configuration
@@ -143,7 +143,7 @@ testMdevctlAutostart(const void *data G_GNUC_UNUSED)
g_autoptr(virCommandDryRunToken) dryRunToken = virCommandDryRunTokenNew();
if (!(def = virNodeDeviceDefParse(NULL, mdevxml, CREATE_DEVICE, VIRT_TYPE,
&parser_callbacks, NULL)))
&parser_callbacks, NULL, false)))
return -1;
virCommandSetDryRun(dryRunToken, &buf, true, true, NULL, NULL);