[libvirt] [PATCH] virsh: add --io when attaching disks to guests

2017-05-12 Thread Gordon Messmer
virt-install and virt-manager both default to explicitly setting "io='native'" in the disk "driver" tag. virsh, however, does not and also does not provide an option to specify that setting at all. As a result, disks use a different IO mechanism (the default, "threads") when attached post-setup

[libvirt] [PATCH] qemu: hotplug: print correct vcpu when validating hot(un)plug config

2017-05-12 Thread Peter Krempa
The error message would contain first vcpu id after the list of vcpus selected for modification. To print the proper vcpu id remember the first vcpu selected to be modified. --- src/qemu/qemu_hotplug.c | 9 +++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git

[libvirt] [PATCH v3] qemu: improve detection of UNIX path generated by libvirt

2017-05-12 Thread Pavel Hrdina
Currently we consider all UNIX paths with specific prefix as generated by libvirt, but that's a wrong assumption. Let's make the detection better by actually checking whether the whole path matches one of the paths that we generate or generated in the past. The UNIX path isn't stored in config

[libvirt] [PATCHv4 8/6] conf: add ABI stability checks for IOMMU options

2017-05-12 Thread Ján Tomko
https://bugzilla.redhat.com/show_bug.cgi?id=1427005 --- src/conf/domain_conf.c | 26 ++ 1 file changed, 26 insertions(+) diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c index 669860c..9eba70a 100644 --- a/src/conf/domain_conf.c +++ b/src/conf/domain_conf.c @@

[libvirt] [PATCHv4 7/6] conf: split out virDomainIOMMUDefCheckABIStability

2017-05-12 Thread Ján Tomko
--- src/conf/domain_conf.c | 24 +--- 1 file changed, 17 insertions(+), 7 deletions(-) diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c index 25dc8c6..669860c 100644 --- a/src/conf/domain_conf.c +++ b/src/conf/domain_conf.c @@ -19819,6 +19819,22 @@

Re: [libvirt] [PATCH] test-wrap-argv.pl: Accept short parameter -i for --in-place

2017-05-12 Thread Pavel Hrdina
On Fri, May 12, 2017 at 04:32:15PM +0200, Martin Kletzander wrote: > On Fri, May 12, 2017 at 04:12:06PM +0200, Pavel Hrdina wrote: > >On Fri, May 12, 2017 at 03:59:46PM +0200, Martin Kletzander wrote: > >> On Fri, May 12, 2017 at 03:15:58PM +0200, Pavel Hrdina wrote: > >> >On Fri, May 12, 2017 at

Re: [libvirt] [PATCH v2 3/3] qemu: improve detection of UNIX path generated by libvirt

2017-05-12 Thread Pavel Hrdina
On Fri, May 12, 2017 at 04:26:35PM +0200, Martin Kletzander wrote: > On Fri, May 12, 2017 at 02:57:56PM +0200, Pavel Hrdina wrote: > >Currently we consider all UNIX paths with specific prefix as generated > >by libvirt, but that's a wrong assumption. Let's make the detection > >better by actually

Re: [libvirt] [PATCH] util: conf: Don't log when adding commented out lines

2017-05-12 Thread Martin Kletzander
On Fri, May 12, 2017 at 04:33:29PM +0200, Peter Krempa wrote: virConfAddEntry spams debug logs even for fully commented out lines. Skip such messages to avoid: 2017-05-12 12:35:38.867+: 10820: debug : virConfAddEntry:241 : Add entry (null) (nil) 2017-05-12 12:35:38.867+: 10820: debug :

Re: [libvirt] [PATCHv4 1/6] conf: add to

2017-05-12 Thread Ján Tomko
On Tue, May 09, 2017 at 01:08:55PM +0200, Andrea Bolognani wrote: On Wed, 2017-05-03 at 16:05 +0200, Ján Tomko wrote: Add a new element with a driver attribute.   Possible values are qemu and kvm. With 'qemu', the I/O APIC can be put in the userspace even for KVM domains.  

[libvirt] [PATCH 1.5/6] qemu: advertise ioapic tuning in the capabilities

2017-05-12 Thread Ján Tomko
Add an element to . https://bugzilla.redhat.com/show_bug.cgi?id=1427005 --- docs/formatcaps.html.in | 3 +++ src/conf/capabilities.c | 3 ++- src/qemu/qemu_capabilities.c | 3 ++- tests/qemucaps2xmldata/all_1.6.0-1.xml

Re: [libvirt] [PATCH v2 1/3] util: introduce virStringMatch

2017-05-12 Thread Pavel Hrdina
On Fri, May 12, 2017 at 04:26:43PM +0200, Martin Kletzander wrote: > On Fri, May 12, 2017 at 02:57:54PM +0200, Pavel Hrdina wrote: > >Simply tries to match the provided regex on a string and returns > >the result. Useful if caller don't care about the matched substring > >and want to just test if

Re: [libvirt] [PATCH] test-wrap-argv.pl: Accept short parameter -i for --in-place

2017-05-12 Thread Martin Kletzander
On Fri, May 12, 2017 at 04:12:06PM +0200, Pavel Hrdina wrote: On Fri, May 12, 2017 at 03:59:46PM +0200, Martin Kletzander wrote: On Fri, May 12, 2017 at 03:15:58PM +0200, Pavel Hrdina wrote: >On Fri, May 12, 2017 at 03:11:27PM +0200, Martin Kletzander wrote: >> I like to use it that way and

[libvirt] [PATCH] util: conf: Don't log when adding commented out lines

2017-05-12 Thread Peter Krempa
virConfAddEntry spams debug logs even for fully commented out lines. Skip such messages to avoid: 2017-05-12 12:35:38.867+: 10820: debug : virConfAddEntry:241 : Add entry (null) (nil) 2017-05-12 12:35:38.867+: 10820: debug : virConfAddEntry:241 : Add entry (null) (nil) 2017-05-12

Re: [libvirt] [PATCH v2 2/3] util: introduce virBufferEscapeRegex

2017-05-12 Thread Martin Kletzander
On Fri, May 12, 2017 at 02:57:55PM +0200, Pavel Hrdina wrote: Add a helper to escape all possible meta-characters used for POSIX extended regular expressions. Signed-off-by: Pavel Hrdina --- new in v2 src/libvirt_private.syms | 1 + src/util/virbuffer.c | 19

Re: [libvirt] [PATCH v2 1/3] util: introduce virStringMatch

2017-05-12 Thread Martin Kletzander
On Fri, May 12, 2017 at 02:57:54PM +0200, Pavel Hrdina wrote: Simply tries to match the provided regex on a string and returns the result. Useful if caller don't care about the matched substring and want to just test if some pattern patches a string. Signed-off-by: Pavel Hrdina

Re: [libvirt] [PATCH v2 3/3] qemu: improve detection of UNIX path generated by libvirt

2017-05-12 Thread Martin Kletzander
On Fri, May 12, 2017 at 02:57:56PM +0200, Pavel Hrdina wrote: Currently we consider all UNIX paths with specific prefix as generated by libvirt, but that's a wrong assumption. Let's make the detection better by actually checking whether the whole path matches one of the paths that we generate

[libvirt] [PATCH v2 RFC 07/12] qemu: backup: add qemuDomainBackupCreateXML implementation

2017-05-12 Thread Nikolay Shirokovskiy
Supported options - backup to file or block device - specify format of backup --- src/conf/backup_conf.c | 32 ++ src/conf/backup_conf.h | 5 +++ src/libvirt_private.syms | 1 + src/qemu/qemu_driver.c | 112 ++- 4 files changed,

[libvirt] [PATCH v2 RFC 00/12] introduce push backups

2017-05-12 Thread Nikolay Shirokovskiy
* Diff from v1 [3] - add man/html docs - add backup xml schema Push backup is a backup when hypervisor itself copy backup data to destination in contrast to pull backup when hypervisor exports backup data thru some interface and mgmt itself make a copy. This patch series basically adds

[libvirt] [PATCH v2 RFC 12/12] docs: add backup html docs

2017-05-12 Thread Nikolay Shirokovskiy
--- docs/Makefile.am | 3 +++ docs/apibuild.py | 2 ++ docs/docs.html.in | 4 +++- docs/format.html.in | 1 + docs/formatbackup.html.in | 58 +++ docs/index.html.in| 3 ++- 6 files changed, 69 insertions(+),

[libvirt] [PATCH v2 RFC 03/12] remote: backup: add create backup implementation

2017-05-12 Thread Nikolay Shirokovskiy
--- daemon/remote.c | 8 src/access/viraccessperm.c | 3 ++- src/access/viraccessperm.h | 6 ++ src/remote/remote_driver.c | 7 +++ src/remote/remote_protocol.x | 23 ++- src/rpc/gendispatch.pl | 29 ++--- 6

[libvirt] [PATCH v2 RFC 02/12] api: backup: add driver based implementation

2017-05-12 Thread Nikolay Shirokovskiy
--- include/libvirt/virterror.h | 2 + src/Makefile.am | 2 + src/datatypes.c | 60 + src/datatypes.h | 29 ++ src/driver-hypervisor.h | 5 ++ src/libvirt-domain-backup.c | 209

[libvirt] [PATCH v2 RFC 06/12] conf: backup: add backup xml definition

2017-05-12 Thread Nikolay Shirokovskiy
Backup xml description is like this: backup name - element is optional. - disk @type attribute is optional, default to 'file'. Valid values are 'file', 'block', 'dir', 'network', 'volume' just as usual for specifing domain disk sources. It specifies backup type. -

[libvirt] [PATCH v2 RFC 04/12] backup: qemu: monitor: add drive-backup command

2017-05-12 Thread Nikolay Shirokovskiy
--- src/qemu/qemu_monitor.c | 14 ++ src/qemu/qemu_monitor.h | 5 + src/qemu/qemu_monitor_json.c | 34 ++ src/qemu/qemu_monitor_json.h | 5 + 4 files changed, 58 insertions(+) diff --git a/src/qemu/qemu_monitor.c

[libvirt] [PATCH v2 RFC 09/12] qemu: backup: prepare backup destination

2017-05-12 Thread Nikolay Shirokovskiy
Prepare here is usual preparation for a disk to be used by qemu made by qemuDomainDiskChainElementPrepare. That is set security labels, add to lock manager and whitelist in cgroups. All three are related to backup target too. Adding to a lock manager is less obvious but can be useful if mirations

[libvirt] [PATCH v2 RFC 05/12] backup: misc: add backup block job type

2017-05-12 Thread Nikolay Shirokovskiy
--- examples/object-events/event-test.c | 3 +++ include/libvirt/libvirt-domain.h| 3 +++ src/conf/domain_conf.c | 2 +- src/qemu/qemu_monitor_json.c| 2 ++ tools/virsh-domain.c| 3 ++- 5 files changed, 11 insertions(+), 2 deletions(-) diff --git

[libvirt] [PATCH v2 RFC 08/12] qemu: backup: check backup destination before start

2017-05-12 Thread Nikolay Shirokovskiy
If backup target is file then check it is not present or regular empty file otherwise. If backup target is block device then check that it is present and block device actually. --- src/qemu/qemu_driver.c | 73 ++ 1 file changed, 73 insertions(+)

[libvirt] [PATCH v2 RFC 01/12] api: backup: add api to create backup

2017-05-12 Thread Nikolay Shirokovskiy
--- include/libvirt/libvirt-domain-backup.h | 59 + include/libvirt/libvirt.h | 1 + 2 files changed, 60 insertions(+) create mode 100644 include/libvirt/libvirt-domain-backup.h diff --git a/include/libvirt/libvirt-domain-backup.h

[libvirt] [PATCH 2/5] tests: Check default GIC version for aarch64/virt TCG guests

2017-05-12 Thread Andrea Bolognani
Signed-off-by: Andrea Bolognani --- .../qemuxml2argv-aarch64-gic-none-tcg.args | 19 .../qemuxml2argv-aarch64-gic-none-tcg.xml | 17 +++ tests/qemuxml2argvtest.c | 3 +++

[libvirt] [PATCH 5/5] news: Update for GIC version on TCG changes

2017-05-12 Thread Andrea Bolognani
Signed-off-by: Andrea Bolognani --- docs/news.xml | 11 +++ 1 file changed, 11 insertions(+) diff --git a/docs/news.xml b/docs/news.xml index 2f01449..4cf14b0 100644 --- a/docs/news.xml +++ b/docs/news.xml @@ -37,6 +37,17 @@ + + +

[libvirt] [PATCH 3/5] qemu: Use GICv2 for aarch64/virt TCG guests

2017-05-12 Thread Andrea Bolognani
There are currently some limitations in the emulated GICv3 that make it unsuitable as a default. Use GICv2 instead. Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1450433 Signed-off-by: Andrea Bolognani --- src/qemu/qemu_domain.c | 41

[libvirt] [PATCH 1/5] qemu: Use qemuDomainMachineIsVirt() more

2017-05-12 Thread Andrea Bolognani
Signed-off-by: Andrea Bolognani --- src/qemu/qemu_capabilities.c | 7 +-- 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/src/qemu/qemu_capabilities.c b/src/qemu/qemu_capabilities.c index 71951e6..cf4dc74 100644 --- a/src/qemu/qemu_capabilities.c +++

[libvirt] [PATCH 4/5] gic: Remove VIR_GIC_VERSION_DEFAULT

2017-05-12 Thread Andrea Bolognani
The QEMU default is GICv2, and some of the code in libvirt relies on the exact value. Stop pretending that's not the case and use GICv2 explicitly where needed. Signed-off-by: Andrea Bolognani --- src/qemu/qemu_command.c | 6 +++--- src/qemu/qemu_domain.c | 7 +++

[libvirt] [PATCH 0/5] qemu: Unbreak aarch64/virt TCG guests

2017-05-12 Thread Andrea Bolognani
This issue was reported on the list a while ago, and now bug reports are popping up in Bugzilla as well. Since the proper fix (implementing the MSI controller for GICv3 in QEMU) has been confirmed to be a long way off, let's deal with it in libvirt. Andrea Bolognani (5): qemu: Use

Re: [libvirt] [PATCH] test-wrap-argv.pl: Accept short parameter -i for --in-place

2017-05-12 Thread Pavel Hrdina
On Fri, May 12, 2017 at 03:59:46PM +0200, Martin Kletzander wrote: > On Fri, May 12, 2017 at 03:15:58PM +0200, Pavel Hrdina wrote: > >On Fri, May 12, 2017 at 03:11:27PM +0200, Martin Kletzander wrote: > >> I like to use it that way and every time I try running it I just > >> instinctively use '-i'

Re: [libvirt] [PATCH] test-wrap-argv.pl: Accept short parameter -i for --in-place

2017-05-12 Thread Ján Tomko
On Fri, May 12, 2017 at 04:00:06PM +0200, Martin Kletzander wrote: On Fri, May 12, 2017 at 03:23:27PM +0200, Ján Tomko wrote: On Fri, May 12, 2017 at 03:11:27PM +0200, Martin Kletzander wrote: I like to use it that way and every time I try running it I just instinctively use '-i' (like with

Re: [libvirt] [PATCH] test-wrap-argv.pl: Accept short parameter -i for --in-place

2017-05-12 Thread Martin Kletzander
On Fri, May 12, 2017 at 03:23:27PM +0200, Ján Tomko wrote: On Fri, May 12, 2017 at 03:11:27PM +0200, Martin Kletzander wrote: I like to use it that way and every time I try running it I just instinctively use '-i' (like with sed, etc.) and it makes sense, IMHO. Signed-off-by: Martin Kletzander

Re: [libvirt] [PATCH] test-wrap-argv.pl: Accept short parameter -i for --in-place

2017-05-12 Thread Martin Kletzander
On Fri, May 12, 2017 at 03:15:58PM +0200, Pavel Hrdina wrote: On Fri, May 12, 2017 at 03:11:27PM +0200, Martin Kletzander wrote: I like to use it that way and every time I try running it I just instinctively use '-i' (like with sed, etc.) and it makes sense, IMHO. Signed-off-by: Martin

Re: [libvirt] [PATCH] docs: install html fonts and related

2017-05-12 Thread Maxim Nestratov
11-May-17 12:15, Daniel P. Berrange пишет: On Thu, May 11, 2017 at 12:01:27PM +0300, Nikolay Shirokovskiy wrote: --- docs/Makefile.am | 22 -- 1 file changed, 20 insertions(+), 2 deletions(-) ACK Regards, Daniel Pushed. Thanks, Maxim -- libvir-list mailing list

Re: [libvirt] changing compat when create volume from volume via libvirt api

2017-05-12 Thread Vasiliy Tolstov
2017-05-12 16:32 GMT+03:00 Vasiliy Tolstov : > Also, specify compat in xml desc of new disk helps with comat version, > but image size grows: > image: new2.qcow2 Sorry for noise. I found root case - old.qcow2 have internal compression enabled when created qcow2 file, but on

[libvirt] [PATCH v2 RFC 11/12] schema: backup: add schema and its tests

2017-05-12 Thread Nikolay Shirokovskiy
--- docs/schemas/domainbackup.rng | 79 ++ tests/domainbackupxml/block_target.xml | 5 ++ tests/domainbackupxml/explicit_description.xml | 6 ++ tests/domainbackupxml/explicit_file_type.xml | 5 ++ tests/domainbackupxml/explicit_format.xml

[libvirt] [PATCH v2 RFC 10/12] virsh: backup: add backup-create command

2017-05-12 Thread Nikolay Shirokovskiy
--- po/POTFILES.in | 1 + tools/Makefile.am| 1 + tools/virsh-backup.c | 100 +++ tools/virsh-backup.h | 29 +++ tools/virsh-util.c | 11 ++ tools/virsh-util.h | 3 ++ tools/virsh.c| 2 ++

Re: [libvirt] changing compat when create volume from volume via libvirt api

2017-05-12 Thread Vasiliy Tolstov
2017-05-12 16:20 GMT+03:00 Vasiliy Tolstov : > I'm use via php binding > https://libvirt.org/html/libvirt-libvirt-storage.html#virStorageVolCreateXMLFrom > > and see that image grows: > > image: new.qcow2 > file format: qcow2 > virtual size: 4.9G (524288 bytes) > disk

Re: [libvirt] [PATCH v2 11/38] Introduce virStreamSkip

2017-05-12 Thread Michal Privoznik
On 05/12/2017 12:56 PM, John Ferlan wrote: > > > On 05/12/2017 03:29 AM, Michal Privoznik wrote: >> On 05/05/2017 04:48 PM, Daniel P. Berrange wrote: >>> On Fri, May 05, 2017 at 01:25:34PM +0200, Michal Privoznik wrote: On 05/04/2017 11:29 PM, John Ferlan wrote: > > > On

Re: [libvirt] [PATCH] test-wrap-argv.pl: Accept short parameter -i for --in-place

2017-05-12 Thread Ján Tomko
On Fri, May 12, 2017 at 03:11:27PM +0200, Martin Kletzander wrote: I like to use it that way and every time I try running it I just instinctively use '-i' (like with sed, etc.) and it makes sense, IMHO. Signed-off-by: Martin Kletzander --- tests/test-wrap-argv.pl | 2 +- 1

[libvirt] changing compat when create volume from volume via libvirt api

2017-05-12 Thread Vasiliy Tolstov
I'm use via php binding https://libvirt.org/html/libvirt-libvirt-storage.html#virStorageVolCreateXMLFrom and see that image grows: image: new.qcow2 file format: qcow2 virtual size: 4.9G (524288 bytes) disk size: 854M cluster_size: 65536 Format specific information: compat: 0.10

Re: [libvirt] [PATCH] test-wrap-argv.pl: Accept short parameter -i for --in-place

2017-05-12 Thread Pavel Hrdina
On Fri, May 12, 2017 at 03:11:27PM +0200, Martin Kletzander wrote: > I like to use it that way and every time I try running it I just > instinctively use '-i' (like with sed, etc.) and it makes sense, IMHO. > > Signed-off-by: Martin Kletzander > --- >

[libvirt] [PATCH] test-wrap-argv.pl: Accept short parameter -i for --in-place

2017-05-12 Thread Martin Kletzander
I like to use it that way and every time I try running it I just instinctively use '-i' (like with sed, etc.) and it makes sense, IMHO. Signed-off-by: Martin Kletzander --- tests/test-wrap-argv.pl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

[libvirt] [PATCH v2 0/3] improve detection of UNIX path generated by libvirt

2017-05-12 Thread Pavel Hrdina
Pavel Hrdina (3): util: introduce virStringMatch util: introduce virBufferEscapeRegex qemu: improve detection of UNIX path generated by libvirt src/libvirt_private.syms | 2 + src/qemu/qemu_domain.c | 51 ++

[libvirt] [PATCH v2 1/3] util: introduce virStringMatch

2017-05-12 Thread Pavel Hrdina
Simply tries to match the provided regex on a string and returns the result. Useful if caller don't care about the matched substring and want to just test if some pattern patches a string. Signed-off-by: Pavel Hrdina --- changes in v2: - virStringMatch returns bool

[libvirt] [PATCH v2 2/3] util: introduce virBufferEscapeRegex

2017-05-12 Thread Pavel Hrdina
Add a helper to escape all possible meta-characters used for POSIX extended regular expressions. Signed-off-by: Pavel Hrdina --- new in v2 src/libvirt_private.syms | 1 + src/util/virbuffer.c | 19 +++ src/util/virbuffer.h | 3 +++

[libvirt] [PATCH v2 3/3] qemu: improve detection of UNIX path generated by libvirt

2017-05-12 Thread Pavel Hrdina
Currently we consider all UNIX paths with specific prefix as generated by libvirt, but that's a wrong assumption. Let's make the detection better by actually checking whether the whole path matches one of the paths that we generate or generated in the past. The UNIX path isn't stored in config

Re: [libvirt] [PATCH] Add support for VNC autoport feature for bhyve hypervisor.

2017-05-12 Thread Alexander Nusov
On Wed, 10 May 2017 17:58:05 +0300 Roman Bogorodskiy bogorods...@gmail.com wrote Alexander Nusov wrote: This patch adds support for automatic VNC port assignment for bhyve guests. --- src/bhyve/bhyve_command.c | 9 + src/bhyve/bhyve_driver.c | 5 +

Re: [libvirt] error in docs https://libvirt.org/html/libvirt-libvirt-domain.html

2017-05-12 Thread Martin Kletzander
On Mon, Apr 24, 2017 at 03:44:08PM +0200, Michal Privoznik wrote: On 04/24/2017 02:34 PM, Vasiliy Tolstov wrote: 2017-04-24 15:30 GMT+03:00 Michal Privoznik : Diggin' deeper, this is problem of apibuild.py script which also generates docs/libvirt-api.xml. So our bindings

Re: [libvirt] [PATCH 2/2] qemu: improve detection of UNIX path generated by libvirt

2017-05-12 Thread Pavel Hrdina
On Fri, May 12, 2017 at 01:28:22PM +0200, Martin Kletzander wrote: > On Fri, May 12, 2017 at 12:02:24PM +0200, Pavel Hrdina wrote: > >On Fri, May 12, 2017 at 11:27:36AM +0200, Martin Kletzander wrote: > >> On Thu, May 11, 2017 at 05:49:54PM +0200, Pavel Hrdina wrote: > >> >Currently we consider

Re: [libvirt] [PATCH] conf: Fix resource leak in virCapabilitiesInitCaches

2017-05-12 Thread Martin Kletzander
On Fri, May 12, 2017 at 06:48:51AM -0400, John Ferlan wrote: The @type from virFileReadValueString needs to be VIR_FREE each time through the loop since it's not saved and since cleanup can be reached prior to decoding it for @kernel_type amd bank->type, the cleanup code needs to also have a

Re: [libvirt] [PATCH 2/2] qemu: improve detection of UNIX path generated by libvirt

2017-05-12 Thread Martin Kletzander
On Fri, May 12, 2017 at 12:02:24PM +0200, Pavel Hrdina wrote: On Fri, May 12, 2017 at 11:27:36AM +0200, Martin Kletzander wrote: On Thu, May 11, 2017 at 05:49:54PM +0200, Pavel Hrdina wrote: >Currently we consider all UNIX paths with specific prefix as generated >by libvirt, but that's a wrong

Re: [libvirt] [PATCH 1/2] util: introduce virStringMatch

2017-05-12 Thread Pavel Hrdina
On Fri, May 12, 2017 at 06:44:16AM -0400, John Ferlan wrote: > > > On 05/11/2017 11:49 AM, Pavel Hrdina wrote: > > Simply tries to match the provided regex on a string and returns > > the result. Useful if caller don't care about the matched substring > > and want to just test if some pattern

Re: [libvirt] [PATCH v2 11/38] Introduce virStreamSkip

2017-05-12 Thread John Ferlan
On 05/12/2017 03:29 AM, Michal Privoznik wrote: > On 05/05/2017 04:48 PM, Daniel P. Berrange wrote: >> On Fri, May 05, 2017 at 01:25:34PM +0200, Michal Privoznik wrote: >>> On 05/04/2017 11:29 PM, John Ferlan wrote: On 04/20/2017 06:01 AM, Michal Privoznik wrote: > This API

[libvirt] [PATCH] conf: Fix resource leak in virCapabilitiesInitCaches

2017-05-12 Thread John Ferlan
The @type from virFileReadValueString needs to be VIR_FREE each time through the loop since it's not saved and since cleanup can be reached prior to decoding it for @kernel_type amd bank->type, the cleanup code needs to also have a VIR_FREE Found by Coverity Signed-off-by: John Ferlan

Re: [libvirt] [PATCH 1/2] util: introduce virStringMatch

2017-05-12 Thread John Ferlan
On 05/11/2017 11:49 AM, Pavel Hrdina wrote: > Simply tries to match the provided regex on a string and returns > the result. Useful if caller don't care about the matched substring > and want to just test if some pattern patches a string. > > Signed-off-by: Pavel Hrdina >

Re: [libvirt] [PATCH 2/2] qemu: improve detection of UNIX path generated by libvirt

2017-05-12 Thread Pavel Hrdina
On Fri, May 12, 2017 at 11:27:36AM +0200, Martin Kletzander wrote: > On Thu, May 11, 2017 at 05:49:54PM +0200, Pavel Hrdina wrote: > >Currently we consider all UNIX paths with specific prefix as generated > >by libvirt, but that's a wrong assumption. Let's make the detection > > > That

Re: [libvirt] [PATCH 2/2] qemu: improve detection of UNIX path generated by libvirt

2017-05-12 Thread Martin Kletzander
On Thu, May 11, 2017 at 05:49:54PM +0200, Pavel Hrdina wrote: Currently we consider all UNIX paths with specific prefix as generated by libvirt, but that's a wrong assumption. Let's make the detection That assumption is pretty OK from my POV, any name that's not generated by libvirt under

Re: [libvirt] [PATCH 1/2] util: introduce virStringMatch

2017-05-12 Thread Martin Kletzander
On Thu, May 11, 2017 at 05:49:53PM +0200, Pavel Hrdina wrote: Simply tries to match the provided regex on a string and returns the result. Useful if caller don't care about the matched substring and want to just test if some pattern patches a string. Signed-off-by: Pavel Hrdina

Re: [libvirt] [PATCH v2 11/38] Introduce virStreamSkip

2017-05-12 Thread Michal Privoznik
On 05/05/2017 04:48 PM, Daniel P. Berrange wrote: > On Fri, May 05, 2017 at 01:25:34PM +0200, Michal Privoznik wrote: >> On 05/04/2017 11:29 PM, John Ferlan wrote: >>> >>> >>> On 04/20/2017 06:01 AM, Michal Privoznik wrote: This API can be used to tell the other side of the stream to skip >>>