Re: [PATCH 2/2] xenParseXM: don't dereference NULL pointer when script is empty

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

 



On 06.10.2011 11:16, Guido Günther wrote:
> O.k. to apply?
>  -- Guido
> 
> ---
>  src/xenxs/xen_xm.c |    6 +++---
>  1 files changed, 3 insertions(+), 3 deletions(-)
> 
> diff --git a/src/xenxs/xen_xm.c b/src/xenxs/xen_xm.c
> index d057043..30188e2 100644
> --- a/src/xenxs/xen_xm.c
> +++ b/src/xenxs/xen_xm.c
> @@ -697,8 +697,8 @@ xenParseXM(virConfPtr conf, int xendConfigVersion,
>                  }
>              }
>  
> -            if (bridge[0] || STREQ(script, "vif-bridge") ||
> -                STREQ(script, "vif-vnic")) {
> +            if (bridge[0] || (script && (STREQ(script, "vif-bridge") ||

I'd rather use STREQ_NULLABLE here.

--
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]