Lines Matching refs:ip_fd
65 static int ip_fd = 0; in tap_alloc() local
84 if( ip_fd ) in tap_alloc()
85 close(ip_fd); in tap_alloc()
87 ip_fd = RETRY_ON_EINTR(open("/dev/udp", O_RDWR, 0)); in tap_alloc()
88 if (ip_fd < 0) { in tap_alloc()
135 if (ioctl (ip_fd, I_POP, NULL) < 0) in tap_alloc()
137 if (ioctl (ip_fd, I_PUSH, "arp") < 0) in tap_alloc()
153 if((ip_muxid = ioctl(ip_fd, I_LINK, if_fd)) < 0){ in tap_alloc()
158 if ((arp_muxid = ioctl (ip_fd, link_type, arp_fd)) < 0) in tap_alloc()
168 if (ioctl (ip_fd, SIOCSLIFMUXID, &ifr) < 0) in tap_alloc()
170 ioctl (ip_fd, I_PUNLINK , arp_muxid); in tap_alloc()
171 ioctl (ip_fd, I_PUNLINK, ip_muxid); in tap_alloc()