diff options
author | Jonathan Mini <mini@FreeBSD.org> | 2002-07-02 08:00:20 +0000 |
---|---|---|
committer | Jonathan Mini <mini@FreeBSD.org> | 2002-07-02 08:00:20 +0000 |
commit | 0830bd135eae1af8fbc5232bd6028e04bec7741d (patch) | |
tree | 7246b8e210a907ac2095a88d0fe80e7eb1a1f7b9 /usr.bin/finger/finger.c | |
parent | 8b768fc82bb8da4ebb188e7db1353ee898ae285a (diff) |
Add -g option, which restricts printing of the gecos fields to just the user's
real name.
PR: bin/39462
Submitted by: Mike Makonnen <makonnen@pacbell.net>
Obtained from: NetBSD
MFC after: 1 week
Notes
Notes:
svn path=/head/; revision=99249
Diffstat (limited to 'usr.bin/finger/finger.c')
-rw-r--r-- | usr.bin/finger/finger.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/usr.bin/finger/finger.c b/usr.bin/finger/finger.c index d5d38c35d47a..0e6c176dc23e 100644 --- a/usr.bin/finger/finger.c +++ b/usr.bin/finger/finger.c @@ -89,7 +89,7 @@ __FBSDID("$FreeBSD$"); DB *db; time_t now; -int entries, lflag, mflag, pplan, sflag, oflag, Tflag; +int entries, gflag, lflag, mflag, pplan, sflag, oflag, Tflag; int d_first = -1; char tbuf[1024]; @@ -107,8 +107,11 @@ option(argc, argv) optind = 1; /* reset getopt */ - while ((ch = getopt(argc, argv, "lmpshoT")) != -1) + while ((ch = getopt(argc, argv, "glmpshoT")) != -1) switch(ch) { + case 'g': + gflag = 1; + break; case 'l': lflag = 1; /* long format */ break; |