X-Git-Url: https://git.tcpdump.org/tcpdump/blobdiff_plain/3d932490b826facb568937a1290910a1265267f5..fb8b947488c7f22b518de1df1a91e663dc7ab33c:/print-rt6.c diff --git a/print-rt6.c b/print-rt6.c index dd55d1fc..822ae7cc 100644 --- a/print-rt6.c +++ b/print-rt6.c @@ -20,8 +20,8 @@ */ #ifndef lint -static const char rcsid[] = - "@(#) $Header: /tcpdump/master/tcpdump/print-rt6.c,v 1.21 2002-08-01 08:53:26 risso Exp $"; +static const char rcsid[] _U_ = + "@(#) $Header: /tcpdump/master/tcpdump/print-rt6.c,v 1.26 2003-11-19 00:36:08 guy Exp $"; #endif #ifdef HAVE_CONFIG_H @@ -38,6 +38,7 @@ static const char rcsid[] = #include "interface.h" #include "addrtoname.h" +#include "extract.h" int rt6_print(register const u_char *bp, register const u_char *bp2) @@ -70,13 +71,13 @@ rt6_print(register const u_char *bp, register const u_char *bp2) #define IPV6_RTHDR_TYPE_2 2 #endif case IPV6_RTHDR_TYPE_0: - case IPV6_RTHDR_TYPE_2: /* Mobile IPv6 ID-17 */ + case IPV6_RTHDR_TYPE_2: /* Mobile IPv6 ID-20 */ dp0 = (struct ip6_rthdr0 *)dp; TCHECK(dp0->ip6r0_reserved); if (dp0->ip6r0_reserved || vflag) { printf(", rsv=0x%0x", - (u_int32_t)ntohl(dp0->ip6r0_reserved)); + EXTRACT_32BITS(&dp0->ip6r0_reserved)); } if (len % 2 == 1) @@ -101,6 +102,6 @@ rt6_print(register const u_char *bp, register const u_char *bp2) trunc: fputs("[|srcrt]", stdout); - return 65535; /* XXX */ + return -1; } #endif /* INET6 */