'struct socket' is exposed to userland via <sys/socketvar.h>.  Most of
our programs in base do not need it.  Since I'm going to change the
content of this struct for MP works, I'd like to reduce the impact on
userland.

Here's a diff to remove useless includes, ok?

Index: sbin/mount_nfs/mount_nfs.c
===================================================================
RCS file: /cvs/src/sbin/mount_nfs/mount_nfs.c,v
retrieving revision 1.53
diff -u -p -r1.53 mount_nfs.c
--- sbin/mount_nfs/mount_nfs.c  27 May 2016 19:45:04 -0000      1.53
+++ sbin/mount_nfs/mount_nfs.c  4 Jan 2018 14:48:07 -0000
@@ -36,7 +36,6 @@
 #include <sys/types.h>
 #include <sys/mount.h>
 #include <sys/socket.h>
-#include <sys/socketvar.h>
 #include <sys/stat.h>
 #include <syslog.h>
 
Index: sbin/nfsd/nfsd.c
===================================================================
RCS file: /cvs/src/sbin/nfsd/nfsd.c,v
retrieving revision 1.37
diff -u -p -r1.37 nfsd.c
--- sbin/nfsd/nfsd.c    31 Aug 2017 06:50:56 -0000      1.37
+++ sbin/nfsd/nfsd.c    4 Jan 2018 14:48:32 -0000
@@ -40,7 +40,6 @@
 #include <sys/ucred.h>
 #include <sys/mount.h>
 #include <sys/socket.h>
-#include <sys/socketvar.h>
 
 #include <rpc/rpc.h>
 #include <rpc/pmap_clnt.h>
Index: sbin/umount/umount.c
===================================================================
RCS file: /cvs/src/sbin/umount/umount.c,v
retrieving revision 1.27
diff -u -p -r1.27 umount.c
--- sbin/umount/umount.c        16 Dec 2016 17:44:59 -0000      1.27
+++ sbin/umount/umount.c        4 Jan 2018 14:48:56 -0000
@@ -34,7 +34,6 @@
 #include <sys/mount.h>
 #include <sys/time.h>
 #include <sys/socket.h>
-#include <sys/socketvar.h>
 
 #include <netdb.h>
 #include <rpc/rpc.h>
Index: usr.bin/showmount/showmount.c
===================================================================
RCS file: /cvs/src/usr.bin/showmount/showmount.c,v
retrieving revision 1.21
diff -u -p -r1.21 showmount.c
--- usr.bin/showmount/showmount.c       21 Jan 2017 11:32:04 -0000      1.21
+++ usr.bin/showmount/showmount.c       4 Jan 2018 14:50:45 -0000
@@ -36,7 +36,6 @@
 #include <sys/types.h>
 #include <sys/file.h>
 #include <sys/socket.h>
-#include <sys/socketvar.h>
 
 #include <netdb.h>
 #include <rpc/rpc.h>
Index: usr.sbin/identd/identd.c
===================================================================
RCS file: /cvs/src/usr.sbin/identd/identd.c,v
retrieving revision 1.38
diff -u -p -r1.38 identd.c
--- usr.sbin/identd/identd.c    4 Jul 2017 01:09:42 -0000       1.38
+++ usr.sbin/identd/identd.c    4 Jan 2018 14:52:34 -0000
@@ -19,7 +19,7 @@
 #include <sys/types.h>
 #include <sys/ioctl.h>
 #include <sys/socket.h>
-#include <sys/socketvar.h>
+#include <sys/queue.h>
 #include <sys/stat.h>
 #include <sys/sysctl.h>
 #include <sys/uio.h>
Index: usr.sbin/npppd/common/radish.c
===================================================================
RCS file: /cvs/src/usr.sbin/npppd/common/radish.c,v
retrieving revision 1.5
diff -u -p -r1.5 radish.c
--- usr.sbin/npppd/common/radish.c      30 May 2017 17:52:05 -0000      1.5
+++ usr.sbin/npppd/common/radish.c      4 Jan 2018 14:52:58 -0000
@@ -41,7 +41,6 @@
 
 #include <sys/types.h>
 #include <sys/socket.h>
-#include <sys/socketvar.h>
 #include <string.h>
 #include <stdlib.h>
 #include <errno.h>
Index: usr.sbin/snmpd/agentx.c
===================================================================
RCS file: /cvs/src/usr.sbin/snmpd/agentx.c,v
retrieving revision 1.10
diff -u -p -r1.10 agentx.c
--- usr.sbin/snmpd/agentx.c     5 Dec 2015 06:42:18 -0000       1.10
+++ usr.sbin/snmpd/agentx.c     4 Jan 2018 14:53:30 -0000
@@ -17,7 +17,7 @@
 
 #include <sys/types.h>
 #include <sys/socket.h>
-#include <sys/socketvar.h>
+#include <sys/queue.h>
 #include <sys/uio.h>
 #include <sys/un.h>
 
Index: usr.sbin/snmpd/traphandler.c
===================================================================
RCS file: /cvs/src/usr.sbin/snmpd/traphandler.c,v
retrieving revision 1.9
diff -u -p -r1.9 traphandler.c
--- usr.sbin/snmpd/traphandler.c        12 Aug 2017 04:29:57 -0000      1.9
+++ usr.sbin/snmpd/traphandler.c        4 Jan 2018 14:53:42 -0000
@@ -18,7 +18,6 @@
 
 #include <sys/queue.h>
 #include <sys/socket.h>
-#include <sys/socketvar.h>
 #include <sys/stat.h>
 #include <sys/types.h>
 #include <sys/uio.h>

Reply via email to