Renamed static usage() to _usage()

This commit is contained in:
Pierre Pronchery 2004-04-11 03:17:33 +00:00
parent b03d07b6df
commit 739f7eb527
3 changed files with 8 additions and 8 deletions

View File

@ -75,7 +75,7 @@ static int _write_nonbuf(int c)
/* usage */ /* usage */
static int usage(void) static int _usage(void)
{ {
fprintf(stderr, "Usage: cat [-u][file ...]\n\ fprintf(stderr, "Usage: cat [-u][file ...]\n\
-u write without delay\n"); -u write without delay\n");
@ -97,7 +97,7 @@ int main(int argc, char * argv[])
flagu = OD_NONE; flagu = OD_NONE;
break; break;
case '?': case '?':
return usage(); return _usage();
} }
} }
return _cat(flagu, argc - optind, &argv[optind]); return _cat(flagu, argc - optind, &argv[optind]);

View File

@ -7,7 +7,7 @@
/* usage */ /* usage */
int usage(void) int _usage(void)
{ {
fprintf(stderr, "%s", "Usage: logname\n"); fprintf(stderr, "%s", "Usage: logname\n");
return 1; return 1;
@ -20,7 +20,7 @@ int main(int argc, char * argv[])
char * lgnm; char * lgnm;
if(argc != 1) if(argc != 1)
return usage(); return _usage();
if((lgnm = getlogin()) == NULL) if((lgnm = getlogin()) == NULL)
{ {
perror("getlogin"); perror("getlogin");

View File

@ -24,7 +24,7 @@ static int _mkfifo(char const * pathname, mode_t mode)
/* usage */ /* usage */
static int usage(void) static int _usage(void)
{ {
fprintf(stderr, "Usage: mkfifo [-m mode] file...\n\ fprintf(stderr, "Usage: mkfifo [-m mode] file...\n\
-m create fifo with the specified mode value\n"); -m create fifo with the specified mode value\n");
@ -46,14 +46,14 @@ int main(int argc, char * argv[])
{ {
case 'm': case 'm':
if((mode = strtol(optarg, NULL, 8)) > 0777) if((mode = strtol(optarg, NULL, 8)) > 0777)
return usage(); return _usage();
break; break;
case '?': case '?':
return usage(); return _usage();
} }
} }
if(argc == optind) if(argc == optind)
return usage(); return _usage();
for(i = optind; i < argc; i++) for(i = optind; i < argc; i++)
if(_mkfifo(argv[i], mode) == 2) if(_mkfifo(argv[i], mode) == 2)
errcode = 2; errcode = 2;