summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorimp <imp@FreeBSD.org>2002-02-19 00:05:59 +0000
committerimp <imp@FreeBSD.org>2002-02-19 00:05:59 +0000
commit60cc340d82f5a470fed8ad4fe6d885a215c0f2c6 (patch)
tree4d682fcb9116e7b87abdc334d07500b7f166fa9a
parent8818100b0fa5f9b2ff855015b36b15b9deb1726f (diff)
downloadFreeBSD-src-60cc340d82f5a470fed8ad4fe6d885a215c0f2c6.zip
FreeBSD-src-60cc340d82f5a470fed8ad4fe6d885a215c0f2c6.tar.gz
Fixed divots that I created when I moved prototypes of group_from_gid
and user_from_uid to grp.h and pwd.h. Update the man pages. Submitted by: David Malone Pointy hat to: imp
-rw-r--r--bin/ls/ls.c2
-rw-r--r--bin/ps/print.c2
-rw-r--r--lib/libc/gen/pwcache.33
-rw-r--r--lib/libc/gen/pwcache.c2
-rw-r--r--usr.bin/find/ls.c8
-rw-r--r--usr.bin/ipcs/ipcs.c2
-rw-r--r--usr.bin/lastcomm/lastcomm.c1
-rw-r--r--usr.sbin/sa/usrdb.c1
8 files changed, 18 insertions, 3 deletions
diff --git a/bin/ls/ls.c b/bin/ls/ls.c
index 466539b..644a4cb 100644
--- a/bin/ls/ls.c
+++ b/bin/ls/ls.c
@@ -58,8 +58,10 @@ static char sccsid[] = "@(#)ls.c 8.5 (Berkeley) 4/2/94";
#include <err.h>
#include <errno.h>
#include <fts.h>
+#include <grp.h>
#include <limits.h>
#include <locale.h>
+#include <pwd.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
diff --git a/bin/ps/print.c b/bin/ps/print.c
index a372a35..4de0dd7 100644
--- a/bin/ps/print.c
+++ b/bin/ps/print.c
@@ -51,10 +51,12 @@ static char sccsid[] = "@(#)print.c 8.6 (Berkeley) 4/16/94";
#include <sys/sysctl.h>
#include <err.h>
+#include <grp.h>
#include <langinfo.h>
#include <locale.h>
#include <math.h>
#include <nlist.h>
+#include <pwd.h>
#include <stddef.h>
#include <stdio.h>
#include <stdlib.h>
diff --git a/lib/libc/gen/pwcache.3 b/lib/libc/gen/pwcache.3
index 0a8c2b0..eb2f9e0 100644
--- a/lib/libc/gen/pwcache.3
+++ b/lib/libc/gen/pwcache.3
@@ -41,9 +41,10 @@
.Sh LIBRARY
.Lb libc
.Sh SYNOPSIS
-.In stdlib.h
+.In pwd.h
.Ft char *
.Fn user_from_uid "unsigned long uid" "int nouser"
+.In grp.h
.Ft char *
.Fn group_from_gid "unsigned long gid" "int nogroup"
.Sh DESCRIPTION
diff --git a/lib/libc/gen/pwcache.c b/lib/libc/gen/pwcache.c
index d573c2d..e5ed90b 100644
--- a/lib/libc/gen/pwcache.c
+++ b/lib/libc/gen/pwcache.c
@@ -40,9 +40,9 @@ __FBSDID("$FreeBSD$");
#include <sys/types.h>
#include <grp.h>
-#include <string.h>
#include <pwd.h>
#include <stdio.h>
+#include <string.h>
#include <utmp.h>
#define NCACHE 64 /* power of 2 */
diff --git a/usr.bin/find/ls.c b/usr.bin/find/ls.c
index d033973..b0ce664 100644
--- a/usr.bin/find/ls.c
+++ b/usr.bin/find/ls.c
@@ -45,13 +45,19 @@ static const char rcsid[] =
#include <err.h>
#include <errno.h>
+#include <fts.h>
+#include <grp.h>
#include <langinfo.h>
+#include <pwd.h>
#include <stdio.h>
#include <string.h>
#include <time.h>
#include <unistd.h>
#include <utmp.h>
+#include "find.h"
+#include "extern.h"
+
/* Derived from the print routines in the ls(1) source code. */
static void printlink __P((char *));
@@ -63,7 +69,7 @@ printlong(name, accpath, sb)
char *accpath; /* current valid path to filename */
struct stat *sb; /* stat buffer */
{
- char modep[15], *user_from_uid(), *group_from_gid();
+ char modep[15];
(void)printf("%6lu %4qd ", (u_long) sb->st_ino, sb->st_blocks);
(void)strmode(sb->st_mode, modep);
diff --git a/usr.bin/ipcs/ipcs.c b/usr.bin/ipcs/ipcs.c
index c335c2b..9b8f440 100644
--- a/usr.bin/ipcs/ipcs.c
+++ b/usr.bin/ipcs/ipcs.c
@@ -33,10 +33,12 @@ static const char rcsid[] =
#include <assert.h>
#include <err.h>
#include <fcntl.h>
+#include <grp.h>
#include <kvm.h>
#include <nlist.h>
#include <limits.h>
#include <paths.h>
+#include <pwd.h>
#include <stddef.h>
#include <stdio.h>
#include <stdlib.h>
diff --git a/usr.bin/lastcomm/lastcomm.c b/usr.bin/lastcomm/lastcomm.c
index 497c7fc..945c17f 100644
--- a/usr.bin/lastcomm/lastcomm.c
+++ b/usr.bin/lastcomm/lastcomm.c
@@ -52,6 +52,7 @@ static const char rcsid[] =
#include <ctype.h>
#include <err.h>
#include <fcntl.h>
+#include <pwd.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
diff --git a/usr.sbin/sa/usrdb.c b/usr.sbin/sa/usrdb.c
index 9ca5f74..3bce1bd 100644
--- a/usr.sbin/sa/usrdb.c
+++ b/usr.sbin/sa/usrdb.c
@@ -39,6 +39,7 @@ static const char rcsid[] =
#include <err.h>
#include <errno.h>
#include <fcntl.h>
+#include <pwd.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
OpenPOWER on IntegriCloud