Assume not only domain object will use it.
---
src/libvirt.c | 20 ++++++++++----------
1 files changed, 10 insertions(+), 10 deletions(-)
diff --git a/src/libvirt.c b/src/libvirt.c
index 700dbef..3de6b13 100644
--- a/src/libvirt.c
+++ b/src/libvirt.c
@@ -3739,15 +3739,15 @@ error:
/* Helper function called to validate incoming client array on any
* interface that sets typed parameters in the hypervisor. */
static int
-virTypedParameterValidateSet(virDomainPtr domain,
+virTypedParameterValidateSet(virConnectPtr conn,
virTypedParameterPtr params,
int nparams)
{
bool string_okay;
int i;
- string_okay = VIR_DRV_SUPPORTS_FEATURE(domain->conn->driver,
- domain->conn,
+ string_okay = VIR_DRV_SUPPORTS_FEATURE(conn->driver,
+ conn,
VIR_DRV_FEATURE_TYPED_PARAM_STRING);
for (i = 0; i < nparams; i++) {
if (strnlen(params[i].field, VIR_TYPED_PARAM_FIELD_LENGTH) ==
@@ -3814,7 +3814,7 @@ virDomainSetMemoryParameters(virDomainPtr domain,
virCheckNonNullArgGoto(params, error);
virCheckPositiveArgGoto(nparams, error);
- if (virTypedParameterValidateSet(domain, params, nparams) < 0)
+ if (virTypedParameterValidateSet(domain->conn, params, nparams) < 0)
goto error;
conn = domain->conn;
@@ -3955,7 +3955,7 @@ virDomainSetNumaParameters(virDomainPtr domain,
}
virCheckNonNullArgGoto(params, error);
virCheckPositiveArgGoto(nparams, error);
- if (virTypedParameterValidateSet(domain, params, nparams) < 0)
+ if (virTypedParameterValidateSet(domain->conn, params, nparams) < 0)
goto error;
conn = domain->conn;
@@ -4083,7 +4083,7 @@ virDomainSetBlkioParameters(virDomainPtr domain,
virCheckNonNullArgGoto(params, error);
virCheckNonNegativeArgGoto(nparams, error);
- if (virTypedParameterValidateSet(domain, params, nparams) < 0)
+ if (virTypedParameterValidateSet(domain->conn, params, nparams) < 0)
goto error;
conn = domain->conn;
@@ -6938,7 +6938,7 @@ virDomainSetSchedulerParameters(virDomainPtr domain,
virCheckNonNullArgGoto(params, error);
virCheckNonNegativeArgGoto(nparams, error);
- if (virTypedParameterValidateSet(domain, params, nparams) < 0)
+ if (virTypedParameterValidateSet(domain->conn, params, nparams) < 0)
goto error;
conn = domain->conn;
@@ -7002,7 +7002,7 @@ virDomainSetSchedulerParametersFlags(virDomainPtr domain,
virCheckNonNullArgGoto(params, error);
virCheckNonNegativeArgGoto(nparams, error);
- if (virTypedParameterValidateSet(domain, params, nparams) < 0)
+ if (virTypedParameterValidateSet(domain->conn, params, nparams) < 0)
goto error;
conn = domain->conn;
@@ -7283,7 +7283,7 @@ virDomainSetInterfaceParameters(virDomainPtr domain,
virCheckNonNullArgGoto(params, error);
virCheckPositiveArgGoto(nparams, error);
- if (virTypedParameterValidateSet(domain, params, nparams) < 0)
+ if (virTypedParameterValidateSet(domain->conn, params, nparams) < 0)
goto error;
conn = domain->conn;
@@ -19088,7 +19088,7 @@ int virDomainSetBlockIoTune(virDomainPtr dom,
virCheckPositiveArgGoto(nparams, error);
virCheckNonNullArgGoto(params, error);
- if (virTypedParameterValidateSet(dom, params, nparams) < 0)
+ if (virTypedParameterValidateSet(dom->conn, params, nparams) < 0)
goto error;
conn = dom->conn;
--
1.7.7.3