stun

simple point to point tunnel
git clone git://git.2f30.org/stun
Log | Files | Refs | README

commit 3df248b6ce0078a080cb82a0f8681461363dbe37
parent 632b5d2419c2c12d097469b295d67ea86d6b7683
Author: sin <sin@2f30.org>
Date:   Tue, 22 Mar 2016 14:42:24 +0000

add freebsd support

Diffstat:
Mstun.c | 6+++---
1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/stun.c b/stun.c @@ -8,7 +8,7 @@ #if defined(__linux__) #include <linux/if_tun.h> #include <bsd/stdlib.h> -#elif defined(__OpenBSD__) +#elif defined(__OpenBSD__) || defined(__FreeBSD__) #include <net/if_tun.h> #elif defined(__DragonFly__) #include <net/tun/if_tun.h> @@ -35,7 +35,7 @@ #include "arg.h" -#if defined(__linux__) || defined(__DragonFly__) +#if defined(__linux__) || defined(__DragonFly__) || defined(__FreeBSD__) #undef explicit_bzero #define explicit_bzero bzero #endif @@ -221,7 +221,7 @@ readtun(int fd, unsigned char *buf, int len) { return read(fd, buf, len); } -#elif defined(__OpenBSD__) || defined(__DragonFly__) +#elif defined(__OpenBSD__) || defined(__DragonFly__) || defined(__FreeBSD__) int opentun(char *tundev) {