Treat virtual network device as tap if Mode = switch or hub.
authorGuus Sliepen <guus@tinc-vpn.org>
Sun, 21 Dec 2008 16:19:31 +0000 (16:19 +0000)
committerGuus Sliepen <guus@tinc-vpn.org>
Sun, 21 Dec 2008 16:19:31 +0000 (16:19 +0000)
On OpenBSD, the link0 flag should still be set in tinc-up or by other means.

src/bsd/device.c

index 5bd253cfe52c8e7ca6a8f7edb8f8dd28fc99f078..3e61431d58b93161e6e0adbb5f37f65eeced315e 100644 (file)
@@ -78,7 +78,7 @@ bool setup_device(void) {
                        return false;
                }
        } else {
-               if(strstr(device, "tap"))
+               if(strstr(device, "tap") || routing_mode != RMODE_ROUTER)
                        device_type = DEVICE_TYPE_TAP;
        }