summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJiri Denemark <jdenemar@redhat.com>2013-01-16 00:42:35 +0100
committerJiri Denemark <jdenemar@redhat.com>2013-01-18 15:04:00 +0100
commit6d36e1dd94071cb6eb6d6148b369d52a63694124 (patch)
treeceb5d51ec328340c2f344e9e75a19529411eaba9
parentadf784e70d09478d5061c400b48972c5afb1a32a (diff)
downloadlibvirt-python-split-6d36e1dd94071cb6eb6d6148b369d52a63694124.zip
libvirt-python-split-6d36e1dd94071cb6eb6d6148b369d52a63694124.tar.gz
libvirt-python-split-6d36e1dd94071cb6eb6d6148b369d52a63694124.tar.xz
Introduce virTypedParamsClear public APIv1.0.2-rc1
The function is just a renamed public version of former virTypedParameterArrayClear.
-rwxr-xr-xgenerator.py1
-rw-r--r--libvirt-override.c59
2 files changed, 21 insertions, 39 deletions
diff --git a/generator.py b/generator.py
index 00e4858..f853d77 100755
--- a/generator.py
+++ b/generator.py
@@ -537,6 +537,7 @@ skip_function = (
"virTypedParamsAddString",
"virTypedParamsAddUInt",
"virTypedParamsAddULLong",
+ "virTypedParamsClear",
"virTypedParamsFree",
"virTypedParamsGet",
"virTypedParamsGetBoolean",
diff --git a/libvirt-override.c b/libvirt-override.c
index 58ed39b..8154024 100644
--- a/libvirt-override.c
+++ b/libvirt-override.c
@@ -367,8 +367,7 @@ libvirt_virDomainBlockStatsFlags(PyObject *self ATTRIBUTE_UNUSED,
ret = getPyVirTypedParameter(params, nparams);
cleanup:
- virTypedParameterArrayClear(params, nparams);
- VIR_FREE(params);
+ virTypedParamsFree(params, nparams);
return ret;
}
@@ -456,7 +455,7 @@ libvirt_virDomainGetCPUStats(PyObject *self ATTRIBUTE_UNUSED, PyObject *args)
start_cpu += queried_ncpus;
ncpus -= queried_ncpus;
- virTypedParameterArrayClear(params, sumparams);
+ virTypedParamsClear(params, sumparams);
}
} else {
LIBVIRT_BEGIN_ALLOW_THREADS;
@@ -498,13 +497,11 @@ libvirt_virDomainGetCPUStats(PyObject *self ATTRIBUTE_UNUSED, PyObject *args)
Py_DECREF(total);
}
- virTypedParameterArrayClear(params, sumparams);
- VIR_FREE(params);
+ virTypedParamsFree(params, sumparams);
return ret;
error:
- virTypedParameterArrayClear(params, sumparams);
- VIR_FREE(params);
+ virTypedParamsFree(params, sumparams);
Py_DECREF(ret);
return error;
}
@@ -668,8 +665,7 @@ libvirt_virDomainGetSchedulerParameters(PyObject *self ATTRIBUTE_UNUSED,
ret = getPyVirTypedParameter(params, nparams);
cleanup:
- virTypedParameterArrayClear(params, nparams);
- VIR_FREE(params);
+ virTypedParamsFree(params, nparams);
return ret;
}
@@ -717,8 +713,7 @@ libvirt_virDomainGetSchedulerParametersFlags(PyObject *self ATTRIBUTE_UNUSED,
ret = getPyVirTypedParameter(params, nparams);
cleanup:
- virTypedParameterArrayClear(params, nparams);
- VIR_FREE(params);
+ virTypedParamsFree(params, nparams);
return ret;
}
@@ -791,8 +786,7 @@ libvirt_virDomainSetSchedulerParameters(PyObject *self ATTRIBUTE_UNUSED,
ret = VIR_PY_INT_SUCCESS;
cleanup:
- virTypedParameterArrayClear(params, nparams);
- VIR_FREE(params);
+ virTypedParamsFree(params, nparams);
VIR_FREE(new_params);
return ret;
}
@@ -868,8 +862,7 @@ libvirt_virDomainSetSchedulerParametersFlags(PyObject *self ATTRIBUTE_UNUSED,
ret = VIR_PY_INT_SUCCESS;
cleanup:
- virTypedParameterArrayClear(params, nparams);
- VIR_FREE(params);
+ virTypedParamsFree(params, nparams);
VIR_FREE(new_params);
return ret;
}
@@ -943,8 +936,7 @@ libvirt_virDomainSetBlkioParameters(PyObject *self ATTRIBUTE_UNUSED,
ret = VIR_PY_INT_SUCCESS;
cleanup:
- virTypedParameterArrayClear(params, nparams);
- VIR_FREE(params);
+ virTypedParamsFree(params, nparams);
VIR_FREE(new_params);
return ret;
}
@@ -991,8 +983,7 @@ libvirt_virDomainGetBlkioParameters(PyObject *self ATTRIBUTE_UNUSED,
ret = getPyVirTypedParameter(params, nparams);
cleanup:
- virTypedParameterArrayClear(params, nparams);
- VIR_FREE(params);
+ virTypedParamsFree(params, nparams);
return ret;
}
@@ -1065,8 +1056,7 @@ libvirt_virDomainSetMemoryParameters(PyObject *self ATTRIBUTE_UNUSED,
ret = VIR_PY_INT_SUCCESS;
cleanup:
- virTypedParameterArrayClear(params, nparams);
- VIR_FREE(params);
+ virTypedParamsFree(params, nparams);
VIR_FREE(new_params);
return ret;
}
@@ -1113,8 +1103,7 @@ libvirt_virDomainGetMemoryParameters(PyObject *self ATTRIBUTE_UNUSED,
ret = getPyVirTypedParameter(params, nparams);
cleanup:
- virTypedParameterArrayClear(params, nparams);
- VIR_FREE(params);
+ virTypedParamsFree(params, nparams);
return ret;
}
@@ -1187,8 +1176,7 @@ libvirt_virDomainSetNumaParameters(PyObject *self ATTRIBUTE_UNUSED,
ret = VIR_PY_INT_SUCCESS;
cleanup:
- virTypedParameterArrayClear(params, nparams);
- VIR_FREE(params);
+ virTypedParamsFree(params, nparams);
VIR_FREE(new_params);
return ret;
}
@@ -1235,8 +1223,7 @@ libvirt_virDomainGetNumaParameters(PyObject *self ATTRIBUTE_UNUSED,
ret = getPyVirTypedParameter(params, nparams);
cleanup:
- virTypedParameterArrayClear(params, nparams);
- VIR_FREE(params);
+ virTypedParamsFree(params, nparams);
return ret;
}
@@ -1310,8 +1297,7 @@ libvirt_virDomainSetInterfaceParameters(PyObject *self ATTRIBUTE_UNUSED,
ret = VIR_PY_INT_SUCCESS;
cleanup:
- virTypedParameterArrayClear(params, nparams);
- VIR_FREE(params);
+ virTypedParamsFree(params, nparams);
VIR_FREE(new_params);
return ret;
}
@@ -1359,8 +1345,7 @@ libvirt_virDomainGetInterfaceParameters(PyObject *self ATTRIBUTE_UNUSED,
ret = getPyVirTypedParameter(params, nparams);
cleanup:
- virTypedParameterArrayClear(params, nparams);
- VIR_FREE(params);
+ virTypedParamsFree(params, nparams);
return ret;
}
@@ -4305,8 +4290,7 @@ libvirt_virDomainSetBlockIoTune(PyObject *self ATTRIBUTE_UNUSED,
ret = VIR_PY_INT_SUCCESS;
cleanup:
- virTypedParameterArrayClear(params, nparams);
- VIR_FREE(params);
+ virTypedParamsFree(params, nparams);
VIR_FREE(new_params);
return ret;
}
@@ -4354,8 +4338,7 @@ libvirt_virDomainGetBlockIoTune(PyObject *self ATTRIBUTE_UNUSED,
ret = getPyVirTypedParameter(params, nparams);
cleanup:
- virTypedParameterArrayClear(params, nparams);
- VIR_FREE(params);
+ virTypedParamsFree(params, nparams);
return ret;
}
@@ -6466,8 +6449,7 @@ libvirt_virNodeSetMemoryParameters(PyObject *self ATTRIBUTE_UNUSED,
ret = VIR_PY_INT_SUCCESS;
cleanup:
- virTypedParameterArrayClear(params, nparams);
- VIR_FREE(params);
+ virTypedParamsFree(params, nparams);
VIR_FREE(new_params);
return ret;
}
@@ -6514,8 +6496,7 @@ libvirt_virNodeGetMemoryParameters(PyObject *self ATTRIBUTE_UNUSED,
ret = getPyVirTypedParameter(params, nparams);
cleanup:
- virTypedParameterArrayClear(params, nparams);
- VIR_FREE(params);
+ virTypedParamsFree(params, nparams);
return ret;
}