Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 19 Feb 2011 17:10:10 +0000 (UTC)
From:      "Bjoern A. Zeeb" <bz@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-projects@freebsd.org
Subject:   svn commit: r218857 - projects/pf/pf45/sys/contrib/pf/net
Message-ID:  <201102191710.p1JHAAW4003379@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: bz
Date: Sat Feb 19 17:10:10 2011
New Revision: 218857
URL: http://svn.freebsd.org/changeset/base/218857

Log:
  Make compile without INET6 (not sure about w/o INET yet).

Modified:
  projects/pf/pf45/sys/contrib/pf/net/pf.c

Modified: projects/pf/pf45/sys/contrib/pf/net/pf.c
==============================================================================
--- projects/pf/pf45/sys/contrib/pf/net/pf.c	Sat Feb 19 17:09:26 2011	(r218856)
+++ projects/pf/pf45/sys/contrib/pf/net/pf.c	Sat Feb 19 17:10:10 2011	(r218857)
@@ -3663,18 +3663,26 @@ pf_test_rule(struct pf_rule **rm, struct
 		    !(th->th_flags & TH_RST)) {
 			u_int32_t	 ack = ntohl(th->th_seq) + pd->p_len;
 			int		 len = 0;
+#ifdef INET
 			struct ip	*h4;
+#endif
+#ifdef INET6
 			struct ip6_hdr	*h6;
+#endif
 
 			switch (af) {
+#ifdef INET
 			case AF_INET:
 				h4 = mtod(m, struct ip *);
 				len = ntohs(h4->ip_len) - off;
 				break;
+#endif
+#ifdef INET6
 			case AF_INET6:
 				h6 = mtod(m, struct ip6_hdr *);
 				len = ntohs(h6->ip6_plen) - (off - sizeof(*h6));
 				break;
+#endif
 			}
 
 			if (pf_check_proto_cksum(m, off, len, IPPROTO_TCP, af))



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201102191710.p1JHAAW4003379>