From 4f082c7df3998cdc2cdf9845a62d886d05257cb8 Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Wed, 30 Apr 2014 02:56:02 +0200 Subject: Remove now unneeded FD_CLOEXEC flag config --- src/tuntap.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/tuntap.c') diff --git a/src/tuntap.c b/src/tuntap.c index d9fd353..d30a392 100644 --- a/src/tuntap.c +++ b/src/tuntap.c @@ -60,7 +60,7 @@ void fastd_tuntap_open(void) { pr_debug("initializing tun/tap device..."); - if ((ctx.tunfd = open("/dev/net/tun", O_RDWR|O_CLOEXEC|O_NONBLOCK)) < 0) + if ((ctx.tunfd = open("/dev/net/tun", O_RDWR|O_NONBLOCK)) < 0) exit_errno("could not open tun/tap device file"); if (conf.ifname) @@ -184,7 +184,7 @@ void fastd_tuntap_open(void) { strncat(ifname, type, IFNAMSIZ-1); } - if ((ctx.tunfd = open(ifname, O_RDWR|O_CLOEXEC|O_NONBLOCK)) < 0) + if ((ctx.tunfd = open(ifname, O_RDWR|O_NONBLOCK)) < 0) exit_errno("could not open tun/tap device file"); if (!(ctx.ifname = fdevname_r(ctx.tunfd, malloc(IFNAMSIZ), IFNAMSIZ))) @@ -254,7 +254,7 @@ void fastd_tuntap_open(void) { pr_debug("initializing tun device..."); - if ((ctx.tunfd = open(ifname, O_RDWR|O_CLOEXEC|O_NONBLOCK)) < 0) + if ((ctx.tunfd = open(ifname, O_RDWR|O_NONBLOCK)) < 0) exit_errno("could not open tun device file"); ctx.ifname = strndup(conf.ifname, IFNAMSIZ-1); -- cgit v1.2.3