Re: [libvirt] [PATCH 9/9] util: json: Privatize struct _virJSONValue and sub-structs

2018-03-30 Thread Ján Tomko
On Fri, Mar 30, 2018 at 12:59:16PM +0200, Peter Krempa wrote: Enforce usage of accessors by hiding the implementation in the code. Signed-off-by: Peter Krempa --- src/util/virjson.c | 39 +++ src/util/virjson.h | 38

Re: [libvirt] [PATCH 8/9] qemu: monitor: Don't resist stealing 'actions' in qemuMonitorJSONTransaction

2018-03-30 Thread Ján Tomko
On Fri, Mar 30, 2018 at 12:59:15PM +0200, Peter Krempa wrote: Rather than trying to prevent stealing of the 'actions' virJSONValue into the monitor command replace the code so that it does the same thing, since 'actions' was actually not really used after calling the monitor. Signed-off-by:

Re: [libvirt] [PATCH 7/9] util: qemu: Don't access virJSONValue members directly in virQEMUBuildCommandLineJSONRecurse

2018-03-30 Thread Ján Tomko
You might be overdoing it with the prefixes. On Fri, Mar 30, 2018 at 12:59:14PM +0200, Peter Krempa wrote: Use the accessors instead. Signed-off-by: Peter Krempa --- src/util/virqemu.c | 8 +--- 1 file changed, 5 insertions(+), 3 deletions(-) ACK Jano

Re: [libvirt] [PATCH 6/9] util: json: Add accessor for geting a VIR_JSON_TYPE_NUMBER as string

2018-03-30 Thread Ján Tomko
On Fri, Mar 30, 2018 at 12:59:13PM +0200, Peter Krempa wrote: Sometimes it's desired to get a JSON number as string. Add a helper. This will help in cases where we'd want to conver the internal type from s/conver/convert/ string to something else. Signed-off-by: Peter Krempa

Re: [libvirt] [PATCH 5/9] json: Replace access to virJSONValue->type by virJSONValueGetType

2018-03-30 Thread Ján Tomko
On Fri, Mar 30, 2018 at 12:59:12PM +0200, Peter Krempa wrote: Signed-off-by: Peter Krempa --- src/qemu/qemu_agent.c| 6 +++--- src/qemu/qemu_monitor_json.c | 18 +- src/util/virqemu.c | 5 +++-- 3 files changed, 15 insertions(+), 14

Re: [libvirt] [PATCH 4/9] qemu: agent: Avoid unnecessary JSON object type check

2018-03-30 Thread Ján Tomko
On Fri, Mar 30, 2018 at 12:59:11PM +0200, Peter Krempa wrote: Use virJSONValueObjectGetArray instead of virJSONValueObjectGet so that it's not necessary to check whether it's an array. Signed-off-by: Peter Krempa --- src/qemu/qemu_agent.c | 8 +--- 1 file changed, 1

Re: [libvirt] [PATCH 3/9] qemu: monitor: Use virJSONValueObjectKeysNumber in qemuMonitorJSONGetCPUModelExpansion

2018-03-30 Thread Ján Tomko
On Fri, Mar 30, 2018 at 12:59:10PM +0200, Peter Krempa wrote: Replace direct access to virJSONValue members by accessor. Signed-off-by: Peter Krempa --- src/qemu/qemu_monitor_json.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) ACK Jano signature.asc

Re: [libvirt] [PATCH 2/9] tests: json: Validate that attribute values are properly stolen

2018-03-30 Thread Ján Tomko
On Fri, Mar 30, 2018 at 12:59:09PM +0200, Peter Krempa wrote: Make sure that the 'a' and 'A' modifiers for virJSONValueObjectAddVArgs behave correctly. Signed-off-by: Peter Krempa --- tests/virjsontest.c | 47 +++ 1 file changed,

Re: [libvirt] [PATCH 1/9] util: json: Fix freeing of objects appended to virJSONValue

2018-03-30 Thread Ján Tomko
On Fri, Mar 30, 2018 at 12:59:08PM +0200, Peter Krempa wrote: It was not possible to determine whether virJSONValueObjectAddVArgs and the functions using it would consume a virJSONValue or not when used with the 'a' or 'A' modifier depending on when the loop failed. Fix this by passing in a

Re: [libvirt] [PATCH] qemu: add virQEMUBuildBufferEscapeComma in qemu_command.c

2018-03-30 Thread Martin Kletzander
On Thu, Mar 29, 2018 at 12:10:46PM -0400, John Ferlan wrote: On 03/16/2018 01:02 PM, Sukrit Bhatnagar wrote: This patch adds virQEMUBuildBufferEscapeComma wherever applicable in src/qemu/qemu_command.c Based on:

Re: [libvirt] [PATCH 08/20] openvz: Use virDomainObjListFindBy{UUID|ID}Ref

2018-03-30 Thread John Ferlan
On 03/29/2018 01:52 PM, Jim Fehlig wrote: > On 03/09/2018 09:48 AM, John Ferlan wrote: >> For openvzDomObjFromDomainLocked and openvzDomainLookupByID >> let's return a locked and referenced @vm object so that callers >> can then use the common and more consistent virDomainObjEndAPI >> in order

Re: [libvirt] [PATCH 06/20] openvz: Create accessors to virDomainObjListFindByUUID

2018-03-30 Thread John Ferlan
On 03/29/2018 01:36 PM, Jim Fehlig wrote: > On 03/09/2018 09:48 AM, John Ferlan wrote: >> Rather than repeat code throughout, create and use a couple of >> accessors in order to lookup by UUID. >> >> Signed-off-by: John Ferlan >> --- >>   src/openvz/openvz_driver.c | 266 >>

Re: [libvirt] [PATCH 0/8] Move the minimum QEMU version closer to 1.3.0

2018-03-30 Thread Ján Tomko
On Thu, Mar 29, 2018 at 02:50:17AM +0200, Ján Tomko wrote: 1.3.0 was released in December 2012, it merged KVM and QEMU and is above our 1.2.0 requirement for QMP capability probing. Ján Tomko (8): virQEMUCapsParseHelpStr: remove unused check_yajl parameter Mandate QEMU >= 0.15.0 Deprecate

[libvirt] [PATCH 42/44] Deprecate QEMU_CAPS_HOST_PCI_MULTIDOMAIN

2018-03-30 Thread Ján Tomko
Implied by QEMU >= 1.2.0. Delete the negative test cases now that they always pass. Signed-off-by: Ján Tomko --- src/qemu/qemu_capabilities.c | 1 - src/qemu/qemu_capabilities.h | 2 +- src/qemu/qemu_command.c

[libvirt] [PATCH 41/44] Deprecate QEMU_CAPS_VNC_SHARE_POLICY

2018-03-30 Thread Ján Tomko
Implied by QEMU >= 1.2.0. Signed-off-by: Ján Tomko --- src/qemu/qemu_capabilities.c | 1 - src/qemu/qemu_capabilities.h | 2 +- src/qemu/qemu_command.c| 7 ---

[libvirt] [PATCH 37/44] Deprecate QEMU_CAPS_DTB

2018-03-30 Thread Ján Tomko
Implied by QEMU >= 1.2.0. Signed-off-by: Ján Tomko --- src/qemu/qemu_capabilities.c | 1 - src/qemu/qemu_capabilities.h | 2 +- src/qemu/qemu_command.c| 11 ++-

[libvirt] [PATCH 38/44] Deprecate QEMU_CAPS_IPV6_MIGRATION

2018-03-30 Thread Ján Tomko
Implied by QEMU >= 1.2.0. Signed-off-by: Ján Tomko --- src/qemu/qemu_capabilities.c | 1 - src/qemu/qemu_capabilities.h | 2 +- src/qemu/qemu_migration.c | 10 +-

[libvirt] [PATCH 27/44] Deprecate QEMU_CAPS_DRIVE_CACHE_DIRECTSYNC

2018-03-30 Thread Ján Tomko
Implied by QEMU >= 1.2.0. Signed-off-by: Ján Tomko --- src/qemu/qemu_capabilities.c | 1 - src/qemu/qemu_capabilities.h | 2 +- src/qemu/qemu_command.c| 7 ---

[libvirt] [PATCH 34/44] Deprecate QEMU_CAPS_WAKEUP

2018-03-30 Thread Ján Tomko
Implied by QEMU >= 1.2.0. Signed-off-by: Ján Tomko --- src/qemu/qemu_capabilities.c | 2 -- src/qemu/qemu_capabilities.h | 2 +- src/qemu/qemu_driver.c | 16

[libvirt] [PATCH 22/44] Deprecate QEMU_CAPS_SMBIOS_TYPE

2018-03-30 Thread Ján Tomko
Implied by QEMU >= 1.2.0. Signed-off-by: Ján Tomko --- src/qemu/qemu_capabilities.c | 1 - src/qemu/qemu_capabilities.h | 2 +- src/qemu/qemu_command.c| 12 ++--

[libvirt] [PATCH 36/44] Deprecate QEMU_CAPS_SECCOMP_SANDBOX

2018-03-30 Thread Ján Tomko
Implied by QEMU >= 1.2.0. Signed-off-by: Ján Tomko --- src/qemu/qemu_capabilities.c | 1 - src/qemu/qemu_capabilities.h | 2 +- src/qemu/qemu_command.c| 14 --

[libvirt] [PATCH 35/44] Deprecate QEMU_CAPS_NETDEV_BRIDGE

2018-03-30 Thread Ján Tomko
Unused since commit <2d80fbb1>. Signed-off-by: Ján Tomko --- src/qemu/qemu_capabilities.c | 1 - src/qemu/qemu_capabilities.h | 2 +- tests/qemucapabilitiesdata/caps_1.3.1.x86_64.xml | 1 -

[libvirt] [PATCH 32/44] Deprecate QEMU_CAPS_FSDEV_WRITEOUT

2018-03-30 Thread Ján Tomko
Implied by QEMU >= 1.2.0. Signed-off-by: Ján Tomko --- src/qemu/qemu_capabilities.c | 1 - src/qemu/qemu_capabilities.h | 2 +- src/qemu/qemu_command.c| 16

[libvirt] [PATCH 33/44] Deprecate QEMU_CAPS_DRIVE_IOTUNE

2018-03-30 Thread Ján Tomko
Implied by QEMU >= 1.2.0. Signed-off-by: Ján Tomko --- src/qemu/qemu_capabilities.c | 1 - src/qemu/qemu_capabilities.h | 2 +- src/qemu/qemu_command.c| 9 - src/qemu/qemu_driver.c

[libvirt] [PATCH 30/44] Deprecate QEMU_CAPS_FSDEV_READONLY

2018-03-30 Thread Ján Tomko
Implied by QEMU >= 1.2.0. Signed-off-by: Ján Tomko --- src/qemu/qemu_capabilities.c | 1 - src/qemu/qemu_capabilities.h | 2 +- src/qemu/qemu_command.c| 12 ++--

[libvirt] [PATCH 21/44] Deprecate QEMU_CAPS_NAME_PROCESS

2018-03-30 Thread Ján Tomko
Implied by QEMU >= 1.2.0. Signed-off-by: Ján Tomko --- src/qemu/qemu_capabilities.c | 1 - src/qemu/qemu_capabilities.h | 2 +- src/qemu/qemu_command.c| 3 +--

[libvirt] [PATCH 26/44] Deprecate QEMU_CAPS_DEVICE_SPICEVMC

2018-03-30 Thread Ján Tomko
The (now assumed) QEMU_CAPS_CHARDEV_SPICEVMC is preferred. Signed-off-by: Ján Tomko --- src/qemu/qemu_capabilities.c | 4 -- src/qemu/qemu_capabilities.h | 2 +- src/qemu/qemu_command.c | 71

[libvirt] [PATCH 20/44] Deprecate QEMU_CAPS_FSDEV

2018-03-30 Thread Ján Tomko
Implied by QEMU >= 1.2.0. Signed-off-by: Ján Tomko --- src/qemu/qemu_capabilities.c | 1 - src/qemu/qemu_capabilities.h | 2 +- src/qemu/qemu_command.c| 6 --

[libvirt] [PATCH 25/44] Deprecate QEMU_CAPS_CHARDEV_SPICEVMC

2018-03-30 Thread Ján Tomko
Implied by QEMU >= 1.2.0. Signed-off-by: Ján Tomko --- src/qemu/qemu_capabilities.c | 4 +--- src/qemu/qemu_capabilities.h | 2 +- src/qemu/qemu_command.c| 5 -

[libvirt] [PATCH 31/44] Deprecate QEMU_CAPS_DRIVE_COPY_ON_READ

2018-03-30 Thread Ján Tomko
Implied by QEMU >= 1.2.0. Signed-off-by: Ján Tomko --- src/qemu/qemu_capabilities.c | 1 - src/qemu/qemu_capabilities.h | 2 +- src/qemu/qemu_command.c| 7 ---

[libvirt] [PATCH 29/44] Deprecate QEMU_CAPS_DRIVE_CACHE_UNSAFE

2018-03-30 Thread Ján Tomko
Implied by QEMU >= 1.2.0. Signed-off-by: Ján Tomko --- src/qemu/qemu_capabilities.c | 1 - src/qemu/qemu_capabilities.h | 2 +- src/qemu/qemu_command.c| 7 ---

[libvirt] [PATCH 12/44] Deprecate QEMU_CAPS_MEM_PATH

2018-03-30 Thread Ján Tomko
Implied by QEMU >= 1.2.0. Signed-off-by: Ján Tomko --- src/qemu/qemu_capabilities.c | 1 - src/qemu/qemu_capabilities.h | 2 +- src/qemu/qemu_command.c| 12 ++

[libvirt] [PATCH 08/44] Remove unused qemuDomainNetVLAN

2018-03-30 Thread Ján Tomko
Signed-off-by: Ján Tomko --- src/qemu/qemu_domain.c | 6 -- src/qemu/qemu_domain.h | 2 -- 2 files changed, 8 deletions(-) diff --git a/src/qemu/qemu_domain.c b/src/qemu/qemu_domain.c index 6b22f9dc3..e4a8c45cf 100644 --- a/src/qemu/qemu_domain.c +++

[libvirt] [PATCH 24/44] Deprecate QEMU_CAPS_DRIVE_AIO

2018-03-30 Thread Ján Tomko
Implied by QEMU >= 1.2.0. Signed-off-by: Ján Tomko --- src/qemu/qemu_capabilities.c | 1 - src/qemu/qemu_capabilities.h | 2 +- src/qemu/qemu_command.c| 7 ---

[libvirt] [PATCH 23/44] Deprecate QEMU_CAPS_VGA_NONE

2018-03-30 Thread Ján Tomko
Last use was removed by commit 0586cf98 deprecating QEMU_CAPS_DEVICE. Signed-off-by: Ján Tomko --- src/qemu/qemu_capabilities.c | 1 - src/qemu/qemu_capabilities.h | 2 +- tests/qemucapabilitiesdata/caps_1.3.1.x86_64.xml | 1 -

[libvirt] [PATCH 17/44] Deprecate QEMU_CAPS_VHOST_NET

2018-03-30 Thread Ján Tomko
Implied by QEMU >= 1.2.0. Signed-off-by: Ján Tomko --- src/qemu/qemu_capabilities.c | 1 - src/qemu/qemu_capabilities.h | 2 +- src/qemu/qemu_command.c| 3 +-- src/qemu/qemu_hotplug.c

[libvirt] [PATCH 06/44] Deprecate QEMU_CAPS_NETDEV

2018-03-30 Thread Ján Tomko
This makes qemuDomainSupportsNetdev identical to qemuDomainSupportsNicdev and leaves some code in qemuDomainAttachNetDevice to be cleaned up later. Signed-off-by: Ján Tomko --- src/qemu/qemu_capabilities.c | 1 - src/qemu/qemu_capabilities.h

[libvirt] [PATCH 07/44] Clean up qemuDomainAttachNetDevice

2018-03-30 Thread Ján Tomko
Now that we assume -netdev support, we no longer set the VLAN or need the hostPlugged bool. Signed-off-by: Ján Tomko --- src/qemu/qemu_hotplug.c | 42 +- 1 file changed, 13 insertions(+), 29 deletions(-) diff --git

[libvirt] [PATCH 09/44] Remove qemuDomainSupportsNetdev

2018-03-30 Thread Ján Tomko
Now that we assume QEMU_CAPS_NETDEV, the only thing left to check is whether we need to use the legacy -net syntax because of a non-conforming armchitecture. Signed-off-by: Ján Tomko --- src/qemu/qemu_command.c | 20 +--- src/qemu/qemu_domain.c| 10

[libvirt] [PATCH 16/44] Deprecate QEMU_CAPS_RTC_TD_HACK

2018-03-30 Thread Ján Tomko
Implied by QEMU >= 0.12.0. Deprecated by QEMU commit 1ed2fc1 included in 0.12.0. Signed-off-by: Ján Tomko --- src/qemu/qemu_capabilities.h | 2 +- src/qemu/qemu_command.c | 21 + 2 files changed, 2 insertions(+), 21 deletions(-) diff --git

[libvirt] [PATCH 04/44] Require QEMU 1.3.0

2018-03-30 Thread Ján Tomko
Released in Dec 2012, the version when the userspace parts of KVM and QEMU fully merged. This lets us drop the -help parsing code and assume lots of capabilities. Signed-off-by: Ján Tomko --- src/qemu/qemu_capabilities.c |7 +-

[libvirt] [PATCH 19/44] Deprecate QEMU_CAPS_BOOT_MENU

2018-03-30 Thread Ján Tomko
Implied by QEMU >= 1.2.0. Signed-off-by: Ján Tomko --- src/qemu/qemu_capabilities.c | 1 - src/qemu/qemu_capabilities.h | 2 +- src/qemu/qemu_command.c | 15 ---

[libvirt] [PATCH 18/44] Deprecate QEMU_CAPS_NODEFCONFIG

2018-03-30 Thread Ján Tomko
Implied by QEMU >= 1.2.0. Signed-off-by: Ján Tomko --- src/qemu/qemu_capabilities.c | 1 - src/qemu/qemu_capabilities.h | 2 +- tests/qemucapabilitiesdata/caps_1.3.1.x86_64.xml | 1 -

[libvirt] [PATCH 14/44] Deprecate QEMU_CAPS_SDL

2018-03-30 Thread Ján Tomko
Implied by QEMU >= 1.2.0. Signed-off-by: Ján Tomko --- src/qemu/qemu_capabilities.c | 4 +--- src/qemu/qemu_capabilities.h | 2 +- src/qemu/qemu_command.c| 9 +

[libvirt] [PATCH 05/44] Deprecate QEMU_CAPS_PCI_MULTIFUNCTION

2018-03-30 Thread Ján Tomko
Supported since QEMU 0.13, but we require QEMU 0.15. Signed-off-by: Ján Tomko --- src/qemu/qemu_capabilities.c | 1 - src/qemu/qemu_capabilities.h | 2 +- src/qemu/qemu_command.c| 15 --

[libvirt] [PATCH 13/44] Deprecate QEMU_CAPS_DRIVE_SERIAL

2018-03-30 Thread Ján Tomko
Implied by QEMU >= 1.2.0. Signed-off-by: Ján Tomko --- src/qemu/qemu_capabilities.c | 1 - src/qemu/qemu_capabilities.h | 2 +- src/qemu/qemu_command.c | 20

[libvirt] [PATCH 00/44] Require QEMU 1.3.0 or newer

2018-03-30 Thread Ján Tomko
It's been a while since we last bumped the minimum QEMU version. Let's get rid of -help parsing and bring our test suite closer to real world usage by implying lots of capabilities. Ján Tomko (44): qemuxml2argvtest: Fix q35-virt-manager capabilities Delete bogus cpu-host-passthrough test

[libvirt] [PATCH 01/44] qemuxml2argvtest: Fix q35-virt-manager capabilities

2018-03-30 Thread Ján Tomko
Use QEMU_CAPS_MACHINE_OPT and QEMU_CAPS_MACHINE_VMPORT_OPT since it specifies . Signed-off-by: Ján Tomko --- tests/qemuxml2argvdata/q35-virt-manager-basic.args | 2 +- tests/qemuxml2argvtest.c | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-)

[libvirt] [PATCH 02/44] Delete bogus cpu-host-passthrough test

2018-03-30 Thread Ján Tomko
We test the same XML for a type='kvm' domain twice, once with QEMU_CAPS_KVM (expecting success), once without (expecting failure). The failure case relies on QEMU_CAPS_MACHINE_OPT not being set, failing in qemuBuildObsoleteAccelArg. Checking a domain-type error message in a cpu test is strange.

Re: [libvirt] [PATCH] docs: formatdomain: Clarify CPU feature policy option "require"

2018-03-30 Thread John Ferlan
On 03/30/2018 06:21 AM, Kashyap Chamarthy wrote: > On Thu, Mar 29, 2018 at 12:22:18PM -0400, John Ferlan wrote: >> >> >> On 03/26/2018 06:53 AM, Kashyap Chamarthy wrote: >>> (Thanks: Jiri Denemark, for clarifying this on IRC.) >> >> Lost context here! That should have gone under the --- cause

Re: [libvirt] [PATCH 2/9] tests: json: Validate that attribute values are properly stolen

2018-03-30 Thread Peter Krempa
On Fri, Mar 30, 2018 at 12:59:09 +0200, Peter Krempa wrote: > Make sure that the 'a' and 'A' modifiers for virJSONValueObjectAddVArgs > behave correctly. > > Signed-off-by: Peter Krempa > --- If you apply this patch without the fix first you get the following error in

Re: [libvirt] [PATCH 0/9] json: Fix leak/double-free, clean up code and privatize virJSONValue

2018-03-30 Thread Peter Krempa
On Fri, Mar 30, 2018 at 12:59:07 +0200, Peter Krempa wrote: > Coverity was not wrong about the usage of 'a'/'A' modifiers for > virJSONValueObjectAddVArgs as noted in [1]. Fix the possible > leak/double-free, and add test to make sure it works as expected. [1]

[libvirt] [PATCH 3/9] qemu: monitor: Use virJSONValueObjectKeysNumber in qemuMonitorJSONGetCPUModelExpansion

2018-03-30 Thread Peter Krempa
Replace direct access to virJSONValue members by accessor. Signed-off-by: Peter Krempa --- src/qemu/qemu_monitor_json.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/qemu/qemu_monitor_json.c b/src/qemu/qemu_monitor_json.c index

[libvirt] [PATCH 6/9] util: json: Add accessor for geting a VIR_JSON_TYPE_NUMBER as string

2018-03-30 Thread Peter Krempa
Sometimes it's desired to get a JSON number as string. Add a helper. This will help in cases where we'd want to conver the internal type from string to something else. Signed-off-by: Peter Krempa --- src/libvirt_private.syms | 1 + src/util/virjson.c | 10 ++

[libvirt] [PATCH 5/9] json: Replace access to virJSONValue->type by virJSONValueGetType

2018-03-30 Thread Peter Krempa
Signed-off-by: Peter Krempa --- src/qemu/qemu_agent.c| 6 +++--- src/qemu/qemu_monitor_json.c | 18 +- src/util/virqemu.c | 5 +++-- 3 files changed, 15 insertions(+), 14 deletions(-) diff --git a/src/qemu/qemu_agent.c

[libvirt] [PATCH 9/9] util: json: Privatize struct _virJSONValue and sub-structs

2018-03-30 Thread Peter Krempa
Enforce usage of accessors by hiding the implementation in the code. Signed-off-by: Peter Krempa --- src/util/virjson.c | 39 +++ src/util/virjson.h | 38 -- 2 files changed, 39 insertions(+), 38

[libvirt] [PATCH 0/9] json: Fix leak/double-free, clean up code and privatize virJSONValue

2018-03-30 Thread Peter Krempa
Coverity was not wrong about the usage of 'a'/'A' modifiers for virJSONValueObjectAddVArgs as noted in [1]. Fix the possible leak/double-free, and add test to make sure it works as expected. This series also cleans up direct access to attributes of virJSONValue and in the end privatizes the

[libvirt] [PATCH 8/9] qemu: monitor: Don't resist stealing 'actions' in qemuMonitorJSONTransaction

2018-03-30 Thread Peter Krempa
Rather than trying to prevent stealing of the 'actions' virJSONValue into the monitor command replace the code so that it does the same thing, since 'actions' was actually not really used after calling the monitor. Signed-off-by: Peter Krempa --- src/qemu/qemu_driver.c

[libvirt] [PATCH 7/9] util: qemu: Don't access virJSONValue members directly in virQEMUBuildCommandLineJSONRecurse

2018-03-30 Thread Peter Krempa
Use the accessors instead. Signed-off-by: Peter Krempa --- src/util/virqemu.c | 8 +--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/util/virqemu.c b/src/util/virqemu.c index e7ea068b94..d6652262fe 100644 --- a/src/util/virqemu.c +++

[libvirt] [PATCH 4/9] qemu: agent: Avoid unnecessary JSON object type check

2018-03-30 Thread Peter Krempa
Use virJSONValueObjectGetArray instead of virJSONValueObjectGet so that it's not necessary to check whether it's an array. Signed-off-by: Peter Krempa --- src/qemu/qemu_agent.c | 8 +--- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/src/qemu/qemu_agent.c

[libvirt] [PATCH 2/9] tests: json: Validate that attribute values are properly stolen

2018-03-30 Thread Peter Krempa
Make sure that the 'a' and 'A' modifiers for virJSONValueObjectAddVArgs behave correctly. Signed-off-by: Peter Krempa --- tests/virjsontest.c | 47 +++ 1 file changed, 47 insertions(+) diff --git a/tests/virjsontest.c

[libvirt] [PATCH 1/9] util: json: Fix freeing of objects appended to virJSONValue

2018-03-30 Thread Peter Krempa
It was not possible to determine whether virJSONValueObjectAddVArgs and the functions using it would consume a virJSONValue or not when used with the 'a' or 'A' modifier depending on when the loop failed. Fix this by passing in a pointer to the pointer so that it can be cleared once it's

Re: [libvirt] [PATCH] docs: formatdomain: Clarify CPU feature policy option "require"

2018-03-30 Thread Kashyap Chamarthy
On Thu, Mar 29, 2018 at 12:22:18PM -0400, John Ferlan wrote: > > > On 03/26/2018 06:53 AM, Kashyap Chamarthy wrote: > > (Thanks: Jiri Denemark, for clarifying this on IRC.) > > Lost context here! That should have gone under the --- cause it'll look > awfully strange in git history. Yeah,