Lines Matching refs:uh
70 struct udphdr *uh;
84 uh = (struct udphdr *)pkt - 1;
85 len += sizeof(*uh);
87 (void)memset(uh, 0, sizeof(*uh));
89 uh->uh_sport = d->myport;
90 uh->uh_dport = d->destport;
91 uh->uh_ulen = htons(len);
93 cc = sendip(d, uh, len, IPPROTO_UDP);
98 return (cc - sizeof(*uh));
109 struct udphdr *uh;
111 uh = (struct udphdr *)pkt - 1;
112 n = readip(d, uh, len + sizeof(*uh), tleft, IPPROTO_UDP);
113 if (n == -1 || (size_t)n < sizeof(*uh))
116 if (uh->uh_dport != d->myport) {
120 ntohs(d->myport), ntohs(uh->uh_dport));
125 if (ntohs(uh->uh_ulen) < sizeof(*uh)) {
129 ntohs(uh->uh_ulen), sizeof(*uh));
134 n -= sizeof(*uh);