]> The Tcpdump Group git mirrors - tcpdump/commitdiff
Protect some IPv6 code with #ifdef INET6/#endif.
authorguy <guy>
Sun, 27 Mar 2005 01:31:25 +0000 (01:31 +0000)
committerguy <guy>
Sun, 27 Mar 2005 01:31:25 +0000 (01:31 +0000)
print-bgp.c

index 57e0c5da7649694c16a92593d6925bef5d6e1723..b53546bf638bf5b10e1d5708c688befeaadd4a87 100644 (file)
@@ -36,7 +36,7 @@
 
 #ifndef lint
 static const char rcsid[] _U_ =
 
 #ifndef lint
 static const char rcsid[] _U_ =
-     "@(#) $Header: /tcpdump/master/tcpdump/print-bgp.c,v 1.90 2005-03-23 09:22:58 hannes Exp $";
+     "@(#) $Header: /tcpdump/master/tcpdump/print-bgp.c,v 1.91 2005-03-27 01:31:25 guy Exp $";
 #endif
 
 #include <tcpdump-stdinc.h>
 #endif
 
 #include <tcpdump-stdinc.h>
@@ -1139,9 +1139,11 @@ bgp_attr_print(const struct bgp_attr *attr, const u_char *pptr, int len)
                                 /* rfc986 mapped IPv4 address ? */
                                 if (EXTRACT_32BITS(tptr+BGP_VPN_RD_LEN) ==  0x47000601)
                                     printf(" = %s", getname(tptr+BGP_VPN_RD_LEN+4));
                                 /* rfc986 mapped IPv4 address ? */
                                 if (EXTRACT_32BITS(tptr+BGP_VPN_RD_LEN) ==  0x47000601)
                                     printf(" = %s", getname(tptr+BGP_VPN_RD_LEN+4));
+#ifdef INET6
                                 /* rfc1888 mapped IPv6 address ? */
                                 else if (EXTRACT_24BITS(tptr+BGP_VPN_RD_LEN) ==  0x350000)
                                     printf(" = %s", getname6(tptr+BGP_VPN_RD_LEN+3));
                                 /* rfc1888 mapped IPv6 address ? */
                                 else if (EXTRACT_24BITS(tptr+BGP_VPN_RD_LEN) ==  0x350000)
                                     printf(" = %s", getname6(tptr+BGP_VPN_RD_LEN+3));
+#endif
                                 tptr += tlen;
                                 tlen = 0;
                             }
                                 tptr += tlen;
                                 tlen = 0;
                             }