Date: Thu, 24 Jul 1997 22:25:52 +1000 From: Bruce Evans <bde@zeta.org.au> To: jkh@time.cdrom.com, TLiddelow@cybec.com.au Cc: freebsd-bugs@hub.freebsd.org, thorpej@nas.nasa.gov Subject: Re: bin/4154: wish /bin/sleep handled fractions of a second. Message-ID: <199707241225.WAA20266@godzilla.zeta.org.au>
next in thread | raw e-mail | index | archive | help
>In this particular case, if you have a script which says something like:
>
>foo
>sleep 0.8
>bar
>sleep 0.9
>baz
>
>And you bring it to a non-BSD system, it will not sleep _at all_ since
>the other system sees "sleep 0", and that could be bad depending on
>what bar and baz do.
It should of course do something like:
sleep: invalid time `0.8' (not a nonnegative decimal integer as specified
by POSIX.2 4.57.4)
sleep: invalid time `0.9' ...
BSD's sleep has the usual sloppy numeric arg checking using atoi(), so it
won't do anything like this.
>This is exactly the kind of interoperability
>problem that POSIX was intended to try and solve. Let's not fight it.
I agree.
Bruce
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199707241225.WAA20266>
