Lines Matching full:sock_fd
1392 int sock_fd = -1, arptype;
1405 sock_fd = device ?
1409 if (sock_fd == -1) {
1429 handle->md.lo_ifindex = iface_get_id(sock_fd, "lo", ebuf);
1446 arptype = iface_get_arptype(sock_fd, device, ebuf);
1468 if (close(sock_fd) == -1) {
1473 sock_fd = socket(PF_PACKET, SOCK_DGRAM,
1475 if (sock_fd == -1) {
1514 handle->md.ifindex = iface_get_id(sock_fd, device, ebuf);
1518 if ((err = iface_bind(sock_fd, handle->md.ifindex,
1566 if (setsockopt(sock_fd, SOL_PACKET,
1577 handle->fd = sock_fd;
1583 if (sock_fd != -1)
1584 close(sock_fd);