diff options
Diffstat (limited to 'toys')
-rw-r--r-- | toys/sleep.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/toys/sleep.c b/toys/sleep.c index 311a2683..ef6d827b 100644 --- a/toys/sleep.c +++ b/toys/sleep.c @@ -39,10 +39,10 @@ void sleep_main(void) // Parse suffix if (*arg) { - int imhd[]={60,3600,86400}; - char *mhd = "mhd", *c = strchr(mhd, *arg); - if (!arg) error_exit("Unknown suffix '%c'", *arg); - d *= imhd[c-mhd]; + int ismhd[]={1,60,3600,86400}; + char *smhd = "smhd", *c = strchr(smhd, *arg); + if (!c) error_exit("Unknown suffix '%c'", *arg); + d *= ismhd[c-smhd]; } tv.tv_nsec=1000000000*(d-(tv.tv_sec = (unsigned long)d)); |