Lines Matching refs:IPOPT_OFFSET
162 if (optlen < IPOPT_OFFSET + sizeof(*cp)) { in ip_dooptions()
166 if ((off = cp[IPOPT_OFFSET]) < IPOPT_MINOFF) { in ip_dooptions()
167 code = &cp[IPOPT_OFFSET] - (u_char *)ip; in ip_dooptions()
266 cp[IPOPT_OFFSET] += sizeof(struct in_addr); in ip_dooptions()
278 if (optlen < IPOPT_OFFSET + sizeof(*cp)) { in ip_dooptions()
279 code = &cp[IPOPT_OFFSET] - (u_char *)ip; in ip_dooptions()
282 if ((off = cp[IPOPT_OFFSET]) < IPOPT_MINOFF) { in ip_dooptions()
283 code = &cp[IPOPT_OFFSET] - (u_char *)ip; in ip_dooptions()
311 cp[IPOPT_OFFSET] += sizeof(struct in_addr); in ip_dooptions()
324 if ((off = cp[IPOPT_OFFSET]) < 5) { in ip_dooptions()
329 cp[IPOPT_OFFSET + 1] += (1 << 4); in ip_dooptions()
330 if ((cp[IPOPT_OFFSET + 1] & 0xf0) == 0) { in ip_dooptions()
331 code = &cp[IPOPT_OFFSET] - (u_char *)ip; in ip_dooptions()
338 switch (cp[IPOPT_OFFSET + 1] & 0x0f) { in ip_dooptions()
346 code = &cp[IPOPT_OFFSET] - (u_char *)ip; in ip_dooptions()
356 cp[IPOPT_OFFSET] += sizeof(struct in_addr); in ip_dooptions()
363 code = &cp[IPOPT_OFFSET] - (u_char *)ip; in ip_dooptions()
370 cp[IPOPT_OFFSET] += sizeof(struct in_addr); in ip_dooptions()
375 code = &cp[IPOPT_OFFSET + 1] - (u_char *)ip; in ip_dooptions()
380 cp[IPOPT_OFFSET] += sizeof(uint32_t); in ip_dooptions()
418 opts->ip_nhops = (olen - IPOPT_OFFSET - 1) / sizeof(struct in_addr); in save_rte()
461 opts->ip_srcrt.srcopt[IPOPT_OFFSET] = IPOPT_MINOFF; in ip_srcroute()
683 bcopy((caddr_t)&cp[IPOPT_OFFSET+1], mtod(m, caddr_t), in ip_pcbopts()
689 bcopy((&cp[IPOPT_OFFSET+1] + sizeof(struct in_addr)), in ip_pcbopts()
690 &cp[IPOPT_OFFSET+1], in ip_pcbopts()
751 if (optlen != IPOPT_OFFSET + sizeof(uint16_t) || in ip_checkrouteralert()
752 (*((uint16_t *)&cp[IPOPT_OFFSET]) != 0)) in ip_checkrouteralert()