aboutsummaryrefslogtreecommitdiff
path: root/tun.c
diff options
context:
space:
mode:
Diffstat (limited to 'tun.c')
-rw-r--r--tun.c13
1 files changed, 2 insertions, 11 deletions
diff --git a/tun.c b/tun.c
index 895409a..aa7f667 100644
--- a/tun.c
+++ b/tun.c
@@ -1369,7 +1369,7 @@ open_tun (const char *dev, const char *dev_type, const char *dev_node, struct tu
if ((tt->fd = open (node, O_RDWR)) < 0)
{
msg (M_WARN | M_ERRNO, "Note: Cannot open TUN/TAP dev %s", node);
- goto linux_2_2_fallback;
+ return;
}
/*
@@ -1413,7 +1413,7 @@ open_tun (const char *dev, const char *dev_type, const char *dev_node, struct tu
if (ioctl (tt->fd, TUNSETIFF, (void *) &ifr) < 0)
{
msg (M_WARN | M_ERRNO, "Note: Cannot ioctl TUNSETIFF %s", dev);
- goto linux_2_2_fallback;
+ return;
}
msg (M_INFO, "TUN/TAP device %s opened", ifr.ifr_name);
@@ -1449,15 +1449,6 @@ open_tun (const char *dev, const char *dev_type, const char *dev_node, struct tu
tt->actual_name = string_alloc (ifr.ifr_name, NULL);
}
return;
-
- linux_2_2_fallback:
- msg (M_INFO, "Note: Attempting fallback to kernel 2.2 TUN/TAP interface");
- if (tt->fd >= 0)
- {
- close (tt->fd);
- tt->fd = -1;
- }
- open_tun_generic (dev, dev_type, dev_node, false, true, tt);
}
#else