Lines Matching refs:curaddr
891 pcap_addr_t *curaddr, *prevaddr, *nextaddr;
896 curaddr = (pcap_addr_t *)malloc(sizeof(pcap_addr_t));
897 if (curaddr == NULL) {
903 curaddr->next = NULL;
905 curaddr->addr = (struct sockaddr *)dup_sockaddr(addr, addr_size);
906 if (curaddr->addr == NULL) {
909 free(curaddr);
913 curaddr->addr = NULL;
916 curaddr->netmask = (struct sockaddr *)dup_sockaddr(netmask, netmask_size);
917 if (curaddr->netmask == NULL) {
920 if (curaddr->addr != NULL)
921 free(curaddr->addr);
922 free(curaddr);
926 curaddr->netmask = NULL;
929 curaddr->broadaddr = (struct sockaddr *)dup_sockaddr(broadaddr, broadaddr_size);
930 if (curaddr->broadaddr == NULL) {
933 if (curaddr->netmask != NULL)
934 free(curaddr->netmask);
935 if (curaddr->addr != NULL)
936 free(curaddr->addr);
937 free(curaddr);
941 curaddr->broadaddr = NULL;
944 curaddr->dstaddr = (struct sockaddr *)dup_sockaddr(dstaddr, dstaddr_size);
945 if (curaddr->dstaddr == NULL) {
948 if (curaddr->broadaddr != NULL)
949 free(curaddr->broadaddr);
950 if (curaddr->netmask != NULL)
951 free(curaddr->netmask);
952 if (curaddr->addr != NULL)
953 free(curaddr->addr);
954 free(curaddr);
958 curaddr->dstaddr = NULL;
977 curdev->addresses = curaddr;
983 prevaddr->next = curaddr;
1200 pcap_addr_t *curaddr, *nextaddr;
1208 for (curaddr = curdev->addresses; curaddr != NULL; curaddr = nextaddr) {
1209 nextaddr = curaddr->next;
1210 if (curaddr->addr)
1211 free(curaddr->addr);
1212 if (curaddr->netmask)
1213 free(curaddr->netmask);
1214 if (curaddr->broadaddr)
1215 free(curaddr->broadaddr);
1216 if (curaddr->dstaddr)
1217 free(curaddr->dstaddr);
1218 free(curaddr);