From owner-svn-src-head@freebsd.org Fri May 11 00:01:45 2018 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 26273FAC032; Fri, 11 May 2018 00:01:45 +0000 (UTC) (envelope-from des@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id C66C76AF81; Fri, 11 May 2018 00:01:44 +0000 (UTC) (envelope-from des@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id A7EA527773; Fri, 11 May 2018 00:01:44 +0000 (UTC) (envelope-from des@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id w4B01i4Z019436; Fri, 11 May 2018 00:01:44 GMT (envelope-from des@FreeBSD.org) Received: (from des@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id w4B01hqD019430; Fri, 11 May 2018 00:01:43 GMT (envelope-from des@FreeBSD.org) Message-Id: <201805110001.w4B01hqD019430@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: des set sender to des@FreeBSD.org using -f From: =?UTF-8?Q?Dag-Erling_Sm=c3=b8rgrav?= Date: Fri, 11 May 2018 00:01:43 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r333475 - in head: lib/libkvm lib/libmemstat sys/sys usr.bin/systat usr.sbin/route6d usr.sbin/rtadvd X-SVN-Group: head X-SVN-Commit-Author: des X-SVN-Commit-Paths: in head: lib/libkvm lib/libmemstat sys/sys usr.bin/systat usr.sbin/route6d usr.sbin/rtadvd X-SVN-Commit-Revision: 333475 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 11 May 2018 00:01:45 -0000 Author: des Date: Fri May 11 00:01:43 2018 New Revision: 333475 URL: https://svnweb.freebsd.org/changeset/base/333475 Log: Reduce pollution. While includes unconditionally, it is only actually used in code which is conditional on _KERNEL. Make the #include itself conditional as well, and fix userland code that uses for other purposes but relied on to bring it in. MFC after: 1 week Modified: head/lib/libkvm/kvm_getswapinfo.c head/lib/libmemstat/memstat.c head/sys/sys/sysctl.h head/usr.bin/systat/ifstat.c head/usr.bin/systat/tcp.c head/usr.sbin/route6d/route6d.c head/usr.sbin/rtadvd/rrenum.c Modified: head/lib/libkvm/kvm_getswapinfo.c ============================================================================== --- head/lib/libkvm/kvm_getswapinfo.c Thu May 10 23:58:33 2018 (r333474) +++ head/lib/libkvm/kvm_getswapinfo.c Fri May 11 00:01:43 2018 (r333475) @@ -33,6 +33,7 @@ __FBSDID("$FreeBSD$"); #include #include #include +#include #include #include Modified: head/lib/libmemstat/memstat.c ============================================================================== --- head/lib/libmemstat/memstat.c Thu May 10 23:58:33 2018 (r333474) +++ head/lib/libmemstat/memstat.c Fri May 11 00:01:43 2018 (r333475) @@ -29,6 +29,7 @@ */ #include +#include #include #include Modified: head/sys/sys/sysctl.h ============================================================================== --- head/sys/sys/sysctl.h Thu May 10 23:58:33 2018 (r333474) +++ head/sys/sys/sysctl.h Fri May 11 00:01:43 2018 (r333475) @@ -38,7 +38,9 @@ #ifndef _SYS_SYSCTL_H_ #define _SYS_SYSCTL_H_ +#ifdef _KERNEL #include +#endif struct thread; /* Modified: head/usr.bin/systat/ifstat.c ============================================================================== --- head/usr.bin/systat/ifstat.c Thu May 10 23:58:33 2018 (r333474) +++ head/usr.bin/systat/ifstat.c Fri May 11 00:01:43 2018 (r333475) @@ -32,6 +32,7 @@ #include #include +#include #include #include #include Modified: head/usr.bin/systat/tcp.c ============================================================================== --- head/usr.bin/systat/tcp.c Thu May 10 23:58:33 2018 (r333474) +++ head/usr.bin/systat/tcp.c Fri May 11 00:01:43 2018 (r333475) @@ -44,6 +44,7 @@ __FBSDID("$FreeBSD$"); #include #include #include +#include #include #include Modified: head/usr.sbin/route6d/route6d.c ============================================================================== --- head/usr.sbin/route6d/route6d.c Thu May 10 23:58:33 2018 (r333474) +++ head/usr.sbin/route6d/route6d.c Fri May 11 00:01:43 2018 (r333475) @@ -39,6 +39,7 @@ static const char _rcsid[] = "$KAME: route6d.c,v 1.104 #include #include #include +#include #include #include #include Modified: head/usr.sbin/rtadvd/rrenum.c ============================================================================== --- head/usr.sbin/rtadvd/rrenum.c Thu May 10 23:58:33 2018 (r333474) +++ head/usr.sbin/rtadvd/rrenum.c Fri May 11 00:01:43 2018 (r333475) @@ -34,6 +34,7 @@ #include #include #include +#include #include #include