Module Name:    src
Committed By:   ozaki-r
Date:           Mon May 13 07:48:42 UTC 2019

Modified Files:
        src/usr.bin/netstat: inet.c inet6.c

Log Message:
Show the number of packets dropped by pfil


To generate a diff of this commit:
cvs rdiff -u -r1.108 -r1.109 src/usr.bin/netstat/inet.c
cvs rdiff -u -r1.71 -r1.72 src/usr.bin/netstat/inet6.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/usr.bin/netstat/inet.c
diff -u src/usr.bin/netstat/inet.c:1.108 src/usr.bin/netstat/inet.c:1.109
--- src/usr.bin/netstat/inet.c:1.108	Thu May  3 07:13:48 2018
+++ src/usr.bin/netstat/inet.c	Mon May 13 07:48:42 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: inet.c,v 1.108 2018/05/03 07:13:48 maxv Exp $	*/
+/*	$NetBSD: inet.c,v 1.109 2019/05/13 07:48:42 ozaki-r Exp $	*/
 
 /*
  * Copyright (c) 1983, 1988, 1993
@@ -34,7 +34,7 @@
 #if 0
 static char sccsid[] = "from: @(#)inet.c	8.4 (Berkeley) 4/20/94";
 #else
-__RCSID("$NetBSD: inet.c,v 1.108 2018/05/03 07:13:48 maxv Exp $");
+__RCSID("$NetBSD: inet.c,v 1.109 2019/05/13 07:48:42 ozaki-r Exp $");
 #endif
 #endif /* not lint */
 
@@ -630,6 +630,8 @@ ip_stats(u_long off, const char *name)
 	p(IP_STAT_OFRAGMENTS, "\t%" PRIu64 " fragment%s created\n");
 	p(IP_STAT_CANTFRAG, "\t%" PRIu64 " datagram%s that can't be fragmented\n");
 	p(IP_STAT_BADADDR, "\t%" PRIu64 " datagram%s with bad address in header\n");
+	p(IP_STAT_PFILDROP_IN, "\t%" PRIu64 " input packet%s dropped by pfil\n");
+	p(IP_STAT_PFILDROP_OUT, "\t%" PRIu64 " output packet%s dropped by pfil\n");
 #undef ps
 #undef p
 }

Index: src/usr.bin/netstat/inet6.c
diff -u src/usr.bin/netstat/inet6.c:1.71 src/usr.bin/netstat/inet6.c:1.72
--- src/usr.bin/netstat/inet6.c:1.71	Thu May  3 07:13:48 2018
+++ src/usr.bin/netstat/inet6.c	Mon May 13 07:48:42 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: inet6.c,v 1.71 2018/05/03 07:13:48 maxv Exp $	*/
+/*	$NetBSD: inet6.c,v 1.72 2019/05/13 07:48:42 ozaki-r Exp $	*/
 /*	BSDI inet.c,v 2.3 1995/10/24 02:19:29 prb Exp	*/
 
 /*
@@ -64,7 +64,7 @@
 #if 0
 static char sccsid[] = "@(#)inet.c	8.4 (Berkeley) 4/20/94";
 #else
-__RCSID("$NetBSD: inet6.c,v 1.71 2018/05/03 07:13:48 maxv Exp $");
+__RCSID("$NetBSD: inet6.c,v 1.72 2019/05/13 07:48:42 ozaki-r Exp $");
 #endif
 #endif /* not lint */
 
@@ -798,6 +798,8 @@ ip6_stats(u_long off, const char *name)
 
 	p1(IP6_STAT_FORWARD_CACHEHIT, "\t%llu forward cache hit\n");
 	p1(IP6_STAT_FORWARD_CACHEMISS, "\t%llu forward cache miss\n");
+	p(IP6_STAT_PFILDROP_IN, "\t%llu input packet%s dropped by pfil\n");
+	p(IP6_STAT_PFILDROP_OUT, "\t%llu output packet%s dropped by pfil\n");
 #undef p
 #undef p1
 }

Reply via email to