bug#9102: "timeout 0 FOO" should timeout right away
From:
Paul Eggert
Subject:
bug#9102: "timeout 0 FOO" should timeout right away
Date:
Sat, 16 Jul 2011 12:34:02 -0700
User-agent:
Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.2.18) Gecko/20110617 Thunderbird/3.1.11
"sleep 0" sleeps for zero seconds, and "timeout 0 FOO"
should timeout in zero seconds as well. Currently,
it doesn't; it times out in an infinite number of seconds.
I see why, from the internals (alarm (0) is a special
call intended to cancel alarms). However, 'timeout' shouldn't
be exposing those internals to users; it should behave like
'sleep' does, as that's more consistent.