Mercurial > hg > toybox
annotate toys/sleep.c @ 186:25447caf1b4b
Change command main() functions to return void, and exit(toys.exitval) from
the toybox infrastructure instead. Eliminates a return call from each command.
author | Rob Landley <rob@landley.net> |
---|---|
date | Thu, 29 Nov 2007 18:14:37 -0600 |
parents | 93da7cc220e6 |
children | 30a6db5a95c2 |
rev | line source |
---|---|
118 | 1 /* vi: set sw=4 ts=4: */ |
2 /* | |
3 * sleep.c - Wait for a number of seconds. | |
4 */ | |
5 | |
6 #include "toys.h" | |
7 | |
186
25447caf1b4b
Change command main() functions to return void, and exit(toys.exitval) from
Rob Landley <rob@landley.net>
parents:
118
diff
changeset
|
8 void sleep_main(void) |
118 | 9 { |
186
25447caf1b4b
Change command main() functions to return void, and exit(toys.exitval) from
Rob Landley <rob@landley.net>
parents:
118
diff
changeset
|
10 toys.exitval = sleep(atol(*toys.optargs)); |
118 | 11 } |