Re: [PATCH 3/3] qemu: XMLToNative: Parse XML as INACTIVE

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

 



On 03/13/2014 01:13 PM, Cole Robinson wrote:
> Right now we are parsing the XML as though it's live, which for example
> will choke on hardcoded XML like:
>
>   <seclabel type='dynamic' model='selinux' relabel='yes'/>
>
> Erroring with:
>
>   $ sudo virsh domxml-to-native qemu-argv f
>   error: XML error: security label is missing
> ---
>  src/qemu/qemu_driver.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/src/qemu/qemu_driver.c b/src/qemu/qemu_driver.c
> index a01739c..89f443f 100644
> --- a/src/qemu/qemu_driver.c
> +++ b/src/qemu/qemu_driver.c
> @@ -5812,7 +5812,8 @@ static char *qemuConnectDomainXMLToNative(virConnectPtr conn,
>          goto cleanup;
>  
>      def = virDomainDefParseString(xmlData, caps, driver->xmlopt,
> -                                  QEMU_EXPECTED_VIRT_TYPES, 0);
> +                                  QEMU_EXPECTED_VIRT_TYPES,
> +                                  VIR_DOMAIN_XML_INACTIVE);
>      if (!def)
>          goto cleanup;
>  

Makes sense to me. ACK.

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list




[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]