- nh = *cp;
- break;
- case IPPROTO_SCTP:
- sctp_print(ndo, cp, (const u_char *)ip6, len);
- return;
- case IPPROTO_DCCP:
- dccp_print(ndo, cp, (const u_char *)ip6, len);
- return;
- case IPPROTO_TCP:
- tcp_print(ndo, cp, len, (const u_char *)ip6, fragmented);
- return;
- case IPPROTO_UDP:
- udp_print(ndo, cp, len, (const u_char *)ip6, fragmented);
- return;
- case IPPROTO_ICMPV6:
- icmp6_print(ndo, cp, len, (const u_char *)ip6, fragmented);
- return;
- case IPPROTO_AH:
- advance = ah_print(ndo, cp);
- nh = *cp;
- break;
- case IPPROTO_ESP:
- {
- int enh, padlen;
- advance = esp_print(ndo, cp, len, (const u_char *)ip6, &enh, &padlen);
- nh = enh & 0xff;
- len -= padlen;
- break;
- }
- case IPPROTO_IPCOMP:
- {
- ipcomp_print(ndo, cp);
- /*
- * Either this has decompressed the payload and
- * printed it, in which case there's nothing more
- * to do, or it hasn't, in which case there's
- * nothing more to do.
- */
- advance = -1;