Date: Wed, 8 Feb 2012 16:45:20 +0000 (UTC) From: "Bjoern A. Zeeb" <bz@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-7@freebsd.org Subject: svn commit: r231213 - stable/7/sys/netinet Message-ID: <201202081645.q18GjKL4051805@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: bz Date: Wed Feb 8 16:45:20 2012 New Revision: 231213 URL: http://svn.freebsd.org/changeset/base/231213 Log: MFC r225036: Hide IPv6 next header parsing warnings under the verbose sysctl so people can possibly disable it when their consoles are flooded, or enabled it for debugging. Modified: stable/7/sys/netinet/ip_fw2.c Directory Properties: stable/7/sys/ (props changed) stable/7/sys/cddl/contrib/opensolaris/ (props changed) stable/7/sys/contrib/dev/acpica/ (props changed) stable/7/sys/contrib/pf/ (props changed) Modified: stable/7/sys/netinet/ip_fw2.c ============================================================================== --- stable/7/sys/netinet/ip_fw2.c Wed Feb 8 16:44:54 2012 (r231212) +++ stable/7/sys/netinet/ip_fw2.c Wed Feb 8 16:45:20 2012 (r231213) @@ -2304,9 +2304,11 @@ do { \ ext_hd |= EXT_RTHDR2; break; default: - printf("IPFW2: IPV6 - Unknown Routing " - "Header type(%d)\n", - ((struct ip6_rthdr *)ulp)->ip6r_type); + if (fw_verbose) + printf("IPFW2: IPV6 - Unknown " + "Routing Header type(%d)\n", + ((struct ip6_rthdr *) + ulp)->ip6r_type); if (fw_deny_unknown_exthdrs) return (IP_FW_DENY); break; @@ -2328,8 +2330,9 @@ do { \ IP6F_MORE_FRAG; if (fw_permit_single_frag6 == 0 && offset == 0 && ip6f_mf == 0) { - printf("IPFW2: IPV6 - Invalid Fragment " - "Header\n"); + if (fw_verbose) + printf("IPFW2: IPV6 - Invalid " + "Fragment Header\n"); if (fw_deny_unknown_exthdrs) return (IP_FW_DENY); break; @@ -2400,8 +2403,10 @@ do { \ break; default: - printf("IPFW2: IPV6 - Unknown Extension " - "Header(%d), ext_hd=%x\n", proto, ext_hd); + if (fw_verbose) + printf("IPFW2: IPV6 - Unknown " + "Extension Header(%d), ext_hd=%x\n", + proto, ext_hd); if (fw_deny_unknown_exthdrs) return (IP_FW_DENY); PULLUP_TO(hlen, ulp, struct ip6_ext);
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201202081645.q18GjKL4051805>