X-Git-Url: https://git.tcpdump.org/tcpdump/blobdiff_plain/69cb46af9119e8b5554bcc4bf1bf36f39cb82131..refs/heads/tcpdump-4.9:/print-sunrpc.c diff --git a/print-sunrpc.c b/print-sunrpc.c index e1da350a..d2366c78 100644 --- a/print-sunrpc.c +++ b/print-sunrpc.c @@ -19,6 +19,8 @@ * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. */ +/* \summary: Sun Remote Procedure Call printer */ + #ifdef HAVE_CONFIG_H #include "config.h" #endif @@ -38,7 +40,7 @@ */ #undef _XOPEN_SOURCE_EXTENDED -#include +#include #if defined(HAVE_GETRPCBYNUMBER) && defined(HAVE_RPC_RPC_H) #include @@ -50,14 +52,12 @@ #include #include -#include "interface.h" +#include "netdissect.h" #include "addrtoname.h" #include "extract.h" #include "ip.h" -#ifdef INET6 #include "ip6.h" -#endif #include "rpc_auth.h" #include "rpc_msg.h" @@ -170,9 +170,7 @@ sunrpcrequest_print(netdissect_options *ndo, register const u_char *bp, { register const struct sunrpc_msg *rp; register const struct ip *ip; -#ifdef INET6 register const struct ip6_hdr *ip6; -#endif uint32_t x; char srcid[20], dstid[20]; /*fits 32bit*/ @@ -195,14 +193,12 @@ sunrpcrequest_print(netdissect_options *ndo, register const u_char *bp, ipaddr_string(ndo, &ip->ip_src), srcid, ipaddr_string(ndo, &ip->ip_dst), dstid, length)); break; -#ifdef INET6 case 6: ip6 = (const struct ip6_hdr *)bp2; ND_PRINT((ndo, "%s.%s > %s.%s: %d", ip6addr_string(ndo, &ip6->ip6_src), srcid, ip6addr_string(ndo, &ip6->ip6_dst), dstid, length)); break; -#endif default: ND_PRINT((ndo, "%s.%s > %s.%s: %d", "?", srcid, "?", dstid, length)); break;