Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 17 Aug 2011 14:39:46 +0000 (UTC)
From:      John Baldwin <jhb@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r224942 - head/sbin/ipfw
Message-ID:  <201108171439.p7HEdkBL009461@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: jhb
Date: Wed Aug 17 14:39:45 2011
New Revision: 224942
URL: http://svn.freebsd.org/changeset/base/224942

Log:
  Fix a regression where a rule containing a source port option after a
  destination IP would incorrectly display the source port as a destination
  port.
  
  Reviewed by:	luigi
  Approved by:	re (kib)
  MFC after:	1 week

Modified:
  head/sbin/ipfw/ipfw2.c

Modified: head/sbin/ipfw/ipfw2.c
==============================================================================
--- head/sbin/ipfw/ipfw2.c	Wed Aug 17 14:29:33 2011	(r224941)
+++ head/sbin/ipfw/ipfw2.c	Wed Aug 17 14:39:45 2011	(r224942)
@@ -1282,6 +1282,8 @@ show_ipfw(struct ip_fw *rule, int pcwidt
 				HAVE_PROTO | HAVE_SRCIP |
 				HAVE_DSTIP | HAVE_IP, 0);
 		case O_IP_SRCPORT:
+			if (flags & HAVE_DSTIP)
+				flags |= HAVE_IP;
 			show_prerequisites(&flags,
 				HAVE_PROTO | HAVE_SRCIP, 0);
 			if ((cmd->len & F_OR) && !or_block)



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