From 813ee9fb62f0ea8c6ca03950a7e930f5cef7a550 Mon Sep 17 00:00:00 2001 From: Peter Krempa Date: Mon, 8 Nov 2021 17:24:50 +0100 Subject: [PATCH] virsh: domain: Replace virJSONValueObjectCreate by virJSONValueObjectAdd MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit virJSONValueObjectAdd now works identically to virJSONValueObjectCreate when used with a NULL argument. Replace all callers. Signed-off-by: Peter Krempa Reviewed-by: Ján Tomko --- tools/virsh-domain.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/tools/virsh-domain.c b/tools/virsh-domain.c index 22f428f702..e9b49307db 100644 --- a/tools/virsh-domain.c +++ b/tools/virsh-domain.c @@ -9623,10 +9623,10 @@ cmdQemuMonitorCommandQMPWrap(vshControl *ctl, } } - if (virJSONValueObjectCreate(&command, - "s:execute", commandname, - "A:arguments", &arguments, - NULL) < 0) + if (virJSONValueObjectAdd(&command, + "s:execute", commandname, + "A:arguments", &arguments, + NULL) < 0) return NULL; return virJSONValueToString(command, false); -- 2.47.2