aboutsummaryrefslogtreecommitdiff
path: root/coreutils/sleep.c
diff options
context:
space:
mode:
authorerik <erik@69ca8d6d-28ef-0310-b511-8ec308f3f277>2000-02-08 19:58:47 +0000
committererik <erik@69ca8d6d-28ef-0310-b511-8ec308f3f277>2000-02-08 19:58:47 +0000
commita18125005d67c38a8ad7fb454571bb996664ad96 (patch)
treec90bda10731ad9333ce3b404f993354c9fc104b8 /coreutils/sleep.c
parent8ef3b44285a8ce5b83bed9cf32ce5f40b30ba72f (diff)
downloadbusybox-w32-a18125005d67c38a8ad7fb454571bb996664ad96.tar.gz
busybox-w32-a18125005d67c38a8ad7fb454571bb996664ad96.tar.bz2
busybox-w32-a18125005d67c38a8ad7fb454571bb996664ad96.zip
Some formatting updates (ran the code through indent)
-Erik git-svn-id: svn://busybox.net/trunk/busybox@357 69ca8d6d-28ef-0310-b511-8ec308f3f277
Diffstat (limited to 'coreutils/sleep.c')
-rw-r--r--coreutils/sleep.c19
1 files changed, 9 insertions, 10 deletions
diff --git a/coreutils/sleep.c b/coreutils/sleep.c
index bfbb78f61..9687b8446 100644
--- a/coreutils/sleep.c
+++ b/coreutils/sleep.c
@@ -1,3 +1,4 @@
1/* vi: set sw=4 ts=4: */
1/* 2/*
2 * Mini sleep implementation for busybox 3 * Mini sleep implementation for busybox
3 * 4 *
@@ -23,19 +24,17 @@
23#include "internal.h" 24#include "internal.h"
24#include <stdio.h> 25#include <stdio.h>
25 26
26const char sleep_usage[] = "sleep N\n\n" 27const char sleep_usage[] = "sleep N\n\n" "Pause for N seconds.\n";
27"Pause for N seconds.\n";
28 28
29extern int 29extern int sleep_main(int argc, char **argv)
30sleep_main(int argc, char * * argv)
31{ 30{
32 if ( (argc < 2) || (**(argv+1) == '-') ) { 31 if ((argc < 2) || (**(argv + 1) == '-')) {
33 usage( sleep_usage ); 32 usage(sleep_usage);
34 } 33 }
35 34
36 if ( sleep(atoi(*(++argv))) != 0 ) { 35 if (sleep(atoi(*(++argv))) != 0) {
37 perror( "sleep"); 36 perror("sleep");
38 exit (FALSE); 37 exit(FALSE);
39 } else 38 } else
40 exit (TRUE); 39 exit(TRUE);
41} 40}