Commit 1313ceb4 authored by Dan McGee's avatar Dan McGee Committed by Stephen Hemminger

iptuntap: avoid double open

would leak a file handle
parent 223f4d8e
......@@ -47,7 +47,7 @@ static void usage(void)
static int tap_add_ioctl(struct ifreq *ifr, uid_t uid, gid_t gid)
{
int fd = open(TUNDEV, O_RDWR);
int fd;
int ret = -1;
#ifdef IFF_TUN_EXCL
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment