Re: [PATCH 3/3] Fix return value usage

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

 



On 08/05/10 - 02:12:52PM, Doug Goldstein wrote:
> Fix the error checking to use the return value from brAddTap() instead
> of checking the current errno value which might have been changed by
> clean up calls inside of brAddTap().
> 
> Signed-off-by: Doug Goldstein <cardoe@xxxxxxxxxx>
> ---
>  src/qemu/qemu_conf.c |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
> 
> diff --git a/src/qemu/qemu_conf.c b/src/qemu/qemu_conf.c
> index e92021a..7c0e354 100644
> --- a/src/qemu/qemu_conf.c
> +++ b/src/qemu/qemu_conf.c
> @@ -1689,7 +1689,7 @@ qemudNetworkIfaceConnect(virConnectPtr conn,
>                          tapmac,
>                          vnet_hdr,
>                          &tapfd))) {
> -        if (errno == ENOTSUP) {
> +        if (err == ENOTSUP) {
>              /* In this particular case, give a better diagnostic. */
>              qemuReportError(VIR_ERR_INTERNAL_ERROR,
>                              _("Failed to add tap interface to bridge. "

Makes sense to me.

ACK

-- 
Chris Lalancette

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