[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: [libvirt] [PATCH v2] qemu: set bind mode for chardev while parsing XML



On 08/30/2017 05:53 PM, Pavel Hrdina wrote:
> Currently while parsing domain XML we clear the UNIX path if it matches
> one of the auto-generated paths by libvirt.  After that when the guest
> is started new path is generated but the mode is also changed to "bind".
> 
> In the real-world use-case the mode should not change, it only happens
> if a user provides a mode='connect' and path that matches one of the
> auto-generated path or not provides a path at all.
> 
> Before *reconnect* feature was introduced there was no issue, but with
> the new feature we need to make sure that it's used only with "connect"
> mode, therefore we need to move the mode change into parsing in order
> to have a proper error reported by validation code.
> 
> Signed-off-by: Pavel Hrdina <phrdina redhat com>
> ---
>  src/qemu/qemu_domain.c                             | 13 +++++++++---
>  ...muxml2argv-chardev-reconnect-generated-path.xml | 23 ++++++++++++++++++++++
>  tests/qemuxml2argvtest.c                           |  3 +++
>  3 files changed, 36 insertions(+), 3 deletions(-)
>  create mode 100644 tests/qemuxml2argvdata/qemuxml2argv-chardev-reconnect-generated-path.xml

Yup, definitely better.

ACK and safe for the freeze.

Michal


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]