virJSONValueObjectAdd now works identically to virJSONValueObjectCreate
when used with a NULL argument. Replace all callers.
Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
}
}
- 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);