]> andersk Git - openssh.git/blobdiff - openbsd-compat/port-tun.c
- (djm) [includes.h monitor.c openbsd-compat/bindresvport.c]
[openssh.git] / openbsd-compat / port-tun.c
index 00a0442b1fc570ef478e5235cfbaa2198ea8df13..cadc331e1a27996f98049b04fdf9cb4a17873cb9 100644 (file)
 
 #include "includes.h"
 
+#include <sys/types.h>
+#include <sys/ioctl.h>
+#include <netinet/in.h>
+#include <netinet/ip.h>
+
+#include <errno.h>
+#include <fcntl.h>
+#include <stdarg.h>
+#include <string.h>
+#include <unistd.h>
+
 #include "log.h"
 #include "misc.h"
-#include "bufaux.h"
+#include "buffer.h"
+#include "channels.h"
 
 /*
  * This is the portable version of the SSH tunnel forwarding, it
@@ -26,6 +38,7 @@
  * settings.
  *
  * SSH_TUN_LINUX       Use the (newer) Linux tun/tap device
+ * SSH_TUN_FREEBSD     Use the FreeBSD tun/tap device
  * SSH_TUN_COMPAT_AF   Translate the OpenBSD address family
  * SSH_TUN_PREPEND_AF  Prepend/remove the address family
  */
@@ -35,6 +48,7 @@
  */
 
 #if defined(SSH_TUN_LINUX)
+#include <linux/if.h>
 #include <linux/if_tun.h>
 
 int
@@ -92,7 +106,10 @@ sys_tun_open(int tun, int mode)
 #ifdef SSH_TUN_FREEBSD
 #include <sys/socket.h>
 #include <net/if.h>
+
+#ifdef HAVE_NET_IF_TUN_H
 #include <net/if_tun.h>
+#endif
 
 int
 sys_tun_open(int tun, int mode)
This page took 0.033022 seconds and 4 git commands to generate.