summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authoralex <alex@FreeBSD.org>1997-08-23 14:28:22 +0000
committeralex <alex@FreeBSD.org>1997-08-23 14:28:22 +0000
commit50eb436640f11382a1fd90f8fb5c2030d5d8acfb (patch)
tree3024529268b9d25d832983d22fb19aa62eefdeca
parent68fb49d725c5ebbcb8152c13476eea9eef00b447 (diff)
downloadFreeBSD-src-50eb436640f11382a1fd90f8fb5c2030d5d8acfb.zip
FreeBSD-src-50eb436640f11382a1fd90f8fb5c2030d5d8acfb.tar.gz
Fixed logging of verbose limited packets.
PR: 4351 Submitted by: Ron Bickers <rbickers@intercenter.net>
-rw-r--r--sys/netinet/ip_fw.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/sys/netinet/ip_fw.c b/sys/netinet/ip_fw.c
index 5401807..22d2200 100644
--- a/sys/netinet/ip_fw.c
+++ b/sys/netinet/ip_fw.c
@@ -12,7 +12,7 @@
*
* This software is provided ``AS IS'' without any warranties of any kind.
*
- * $Id: ip_fw.c,v 1.60 1997/08/02 14:32:51 bde Exp $
+ * $Id: ip_fw.c,v 1.61 1997/08/06 00:19:05 alex Exp $
*/
/*
@@ -257,6 +257,10 @@ ipfw_report(struct ip_fw *f, struct ip *ip,
struct icmp *const icmp = (struct icmp *) ((u_long *) ip + ip->ip_hl);
int count;
+ count = f ? f->fw_pcnt : ++counter;
+ if (fw_verbose_limit != 0 && count > fw_verbose_limit)
+ return;
+
/* Print command name */
printf("ipfw: %d ", f ? f->fw_number : -1);
if (!f)
@@ -293,9 +297,6 @@ ipfw_report(struct ip_fw *f, struct ip *ip,
}
printf(" ");
- count = f ? f->fw_pcnt : ++counter;
- if (fw_verbose_limit != 0 && count > fw_verbose_limit)
- return;
switch (ip->ip_p) {
case IPPROTO_TCP:
printf("TCP ");
OpenPOWER on IntegriCloud