diff options
author | imp <imp@FreeBSD.org> | 2002-02-02 06:15:22 +0000 |
---|---|---|
committer | imp <imp@FreeBSD.org> | 2002-02-02 06:15:22 +0000 |
commit | 41e5cc1a95a5bfa252a69404fcb3cd5e9eaec898 (patch) | |
tree | 6322786c2b91ab96c1f709f394e8db65851d90b8 /bin/chmod | |
parent | ef44ec93a71d6f956cf008bf3f58ad2fc4623a4f (diff) | |
download | FreeBSD-src-41e5cc1a95a5bfa252a69404fcb3cd5e9eaec898.zip FreeBSD-src-41e5cc1a95a5bfa252a69404fcb3cd5e9eaec898.tar.gz |
Modernization effort for bin/c*:
o __P has been reoved
o Old-style K&R declarations have been converted to new C89 style
o register has been removed
o prototype for main() has been removed (gcc3 makes it an error)
o int main(int argc, char *argv[]) is the preferred main definition.
o Attempt to not break style(9) conformance for declarations more than
they already are.
Approved by: arch@, new style(9)
Diffstat (limited to 'bin/chmod')
-rw-r--r-- | bin/chmod/chmod.c | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/bin/chmod/chmod.c b/bin/chmod/chmod.c index 83a31c7d..295e210 100644 --- a/bin/chmod/chmod.c +++ b/bin/chmod/chmod.c @@ -57,13 +57,11 @@ static const char rcsid[] = #include <string.h> #include <unistd.h> -int main __P((int, char *[])); -void usage __P((void)); +int main(int, char *[]); +void usage(void); int -main(argc, argv) - int argc; - char *argv[]; +main(int argc, char *argv[]) { FTS *ftsp; FTSENT *p; @@ -74,7 +72,7 @@ main(argc, argv) int vflag; char *ep, *mode; int newmode; - int (*change_mode) __P((const char *, mode_t)); + int (*change_mode)(const char *, mode_t); set = NULL; omode = 0; @@ -222,7 +220,7 @@ done: argv += optind; } void -usage() +usage(void) { (void)fprintf(stderr, "usage: chmod [-fhv] [-R [-H | -L | -P]] mode file ...\n"); |