mirror of
https://github.com/sheumann/hush.git
synced 2024-12-21 23:29:34 +00:00
Start the great EXIT_{SUCCESS,FAILURE} migration.
This commit is contained in:
parent
d995493987
commit
90f580ad5b
@ -34,7 +34,7 @@ extern int yes_main(int argc, char **argv)
|
|||||||
while (1)
|
while (1)
|
||||||
if (puts("y") == EOF) {
|
if (puts("y") == EOF) {
|
||||||
perror("yes");
|
perror("yes");
|
||||||
exit(FALSE);
|
return EXIT_FAILURE;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -43,7 +43,8 @@ extern int yes_main(int argc, char **argv)
|
|||||||
if (fputs(argv[i], stdout) == EOF
|
if (fputs(argv[i], stdout) == EOF
|
||||||
|| putchar(i == argc - 1 ? '\n' : ' ') == EOF) {
|
|| putchar(i == argc - 1 ? '\n' : ' ') == EOF) {
|
||||||
perror("yes");
|
perror("yes");
|
||||||
exit(FALSE);
|
return EXIT_FAILURE;
|
||||||
}
|
}
|
||||||
exit(TRUE);
|
|
||||||
|
return EXIT_SUCCESS;
|
||||||
}
|
}
|
||||||
|
7
yes.c
7
yes.c
@ -34,7 +34,7 @@ extern int yes_main(int argc, char **argv)
|
|||||||
while (1)
|
while (1)
|
||||||
if (puts("y") == EOF) {
|
if (puts("y") == EOF) {
|
||||||
perror("yes");
|
perror("yes");
|
||||||
exit(FALSE);
|
return EXIT_FAILURE;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -43,7 +43,8 @@ extern int yes_main(int argc, char **argv)
|
|||||||
if (fputs(argv[i], stdout) == EOF
|
if (fputs(argv[i], stdout) == EOF
|
||||||
|| putchar(i == argc - 1 ? '\n' : ' ') == EOF) {
|
|| putchar(i == argc - 1 ? '\n' : ' ') == EOF) {
|
||||||
perror("yes");
|
perror("yes");
|
||||||
exit(FALSE);
|
return EXIT_FAILURE;
|
||||||
}
|
}
|
||||||
exit(TRUE);
|
|
||||||
|
return EXIT_SUCCESS;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user