On Tue, Jul 02, 2019 at 03:49:41PM +0200, Ilias Stamatis wrote:
This macro can be used by most or all of the DomainGetXXXParameters
APIs.
Technically okay, but usually we introduce such helper macros with the first
function that needs it, solely because a patch such as this is effectively a
NOP wit the #undef, so I'll squash this patch into 2/4.
Reviewed-by: Erik Skultety <eskultet(a)redhat.com>
Signed-off-by: Ilias Stamatis <stamatis.iliass(a)gmail.com>
---
src/test/test_driver.c | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/src/test/test_driver.c b/src/test/test_driver.c
index 4b1f2724a0..c0608a4bea 100644
--- a/src/test/test_driver.c
+++ b/src/test/test_driver.c
@@ -2844,6 +2844,16 @@ static char *testDomainGetXMLDesc(virDomainPtr domain, unsigned
int flags)
return ret;
}
+
+#define TEST_SET_PARAM(index, name, type, value) \
+ if (index < *nparams && \
+ virTypedParameterAssign(¶ms[index], name, type, value) < 0) \
+ goto cleanup
+
+
+#undef TEST_SET_PARAM
+
+
static int testConnectNumOfDefinedDomains(virConnectPtr conn)
{
testDriverPtr privconn = conn->privateData;
--
2.22.0
--
libvir-list mailing list
libvir-list(a)redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list