Home
last modified time | relevance | path

Searched refs:bindaddr (Results 1 – 1 of 1) sorted by relevance

/system/core/libnetutils/
Dpacket.c45 struct sockaddr_ll bindaddr; in open_raw_socket() local
51 memset(&bindaddr, 0, sizeof(bindaddr)); in open_raw_socket()
52 bindaddr.sll_family = AF_PACKET; in open_raw_socket()
53 bindaddr.sll_protocol = htons(ETH_P_IP); in open_raw_socket()
54 bindaddr.sll_halen = ETH_ALEN; in open_raw_socket()
55 memcpy(bindaddr.sll_addr, hwaddr, ETH_ALEN); in open_raw_socket()
56 bindaddr.sll_ifindex = if_index; in open_raw_socket()
58 if (bind(s, (struct sockaddr *)&bindaddr, sizeof(bindaddr)) < 0) { in open_raw_socket()