aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDoug Goldstein <cardoe@gentoo.org>2010-08-05 11:32:47 -0500
committerDoug Goldstein <cardoe@gentoo.org>2010-08-05 14:26:33 -0500
commitc1584ac9485a40fd82da9b8ebdcce453b6eaa3fe (patch)
treeb3a9a8d0a3bc507658ac5212b67531c313d139c7
parentAdd a detailed message when tap device add fails (diff)
downloadlibvirt-c1584ac9485a40fd82da9b8ebdcce453b6eaa3fe.tar.gz
libvirt-c1584ac9485a40fd82da9b8ebdcce453b6eaa3fe.tar.bz2
libvirt-c1584ac9485a40fd82da9b8ebdcce453b6eaa3fe.zip
Fix return value usage
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@gentoo.org>
-rw-r--r--src/qemu/qemu_conf.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/qemu/qemu_conf.c b/src/qemu/qemu_conf.c
index 701d1d4ea..ad085d13f 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. "