diff options
author | dwmalone <dwmalone@FreeBSD.org> | 2002-09-04 23:29:10 +0000 |
---|---|---|
committer | dwmalone <dwmalone@FreeBSD.org> | 2002-09-04 23:29:10 +0000 |
commit | b4339b74aded4c38ebcfe3a2a9b37b900abb8874 (patch) | |
tree | fb230419005f211ecea1e667385bde9886dbf0d8 /usr.bin/id/id.c | |
parent | 228b93ce829543fee06561687a63c17a7e821dfd (diff) | |
download | FreeBSD-src-b4339b74aded4c38ebcfe3a2a9b37b900abb8874.zip FreeBSD-src-b4339b74aded4c38ebcfe3a2a9b37b900abb8874.tar.gz |
ANSIify function definitions.
Add some constness to avoid some warnings.
Remove use register keyword.
Deal with missing/unneeded extern/prototypes.
Some minor type changes/casts to avoid warnings.
Reviewed by: md5
Diffstat (limited to 'usr.bin/id/id.c')
-rw-r--r-- | usr.bin/id/id.c | 24 |
1 files changed, 8 insertions, 16 deletions
diff --git a/usr.bin/id/id.c b/usr.bin/id/id.c index 5d43e9f..2d4eee7 100644 --- a/usr.bin/id/id.c +++ b/usr.bin/id/id.c @@ -67,9 +67,7 @@ struct passwd * int isgroups, iswhoami; int -main(argc, argv) - int argc; - char *argv[]; +main(int argc, char *argv[]) { struct group *gr; struct passwd *pw; @@ -177,8 +175,7 @@ main(argc, argv) } void -pretty(pw) - struct passwd *pw; +pretty(struct passwd *pw) { struct group *gr; u_int eid, rid; @@ -218,7 +215,7 @@ pretty(pw) } void -current() +current(void) { struct group *gr; struct passwd *pw; @@ -259,8 +256,7 @@ current() } void -user(pw) - struct passwd *pw; +user(struct passwd *pw) { struct group *gr; const char *fmt; @@ -287,9 +283,7 @@ user(pw) } void -group(pw, nflag) - struct passwd *pw; - int nflag; +group(struct passwd *pw, int nflag) { struct group *gr; int cnt, id, lastid, ngroups; @@ -324,8 +318,7 @@ group(pw, nflag) } struct passwd * -who(u) - char *u; +who(char *u) { struct passwd *pw; long id; @@ -345,8 +338,7 @@ who(u) } void -pline(pw) - struct passwd *pw; +pline(struct passwd *pw) { u_int rid; @@ -363,7 +355,7 @@ pline(pw) void -usage() +usage(void) { if (isgroups) |