[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#51128: timeout --kill-after=0 seems to not send a kill 0s after the
From: |
Pádraig Brady |
Subject: |
bug#51128: timeout --kill-after=0 seems to not send a kill 0s after the initial signal |
Date: |
Tue, 12 Oct 2021 14:53:17 +0100 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:84.0) Gecko/20100101 Thunderbird/84.0 |
On 12/10/2021 02:21, Christoph Anton Mitterer wrote:
Hey.
One more thing on this, since I've just read through:
https://www.gnu.org/software/coreutils/manual/html_node/timeout-invocation.html#timeout-invocation
That does IMO *not* document the behaviour:
--kill-after=duration says:
This option has no effect if timeout’s duration is 0 which disables
the associated timeout.
But that's about the timeout from the command itself (i.e. the 1st non-
option argument), isn't it?
So it means that if I have:
timeout --kill-after=10 0 ./command
There won't be a KILL after 10s, since the duration itself is 0.
Right. That is the behavior.
There's no word about that --kill-after=0 disabling the KILL in the
duration != 0 case as in:
timeout --kill-after=0 10 ./command
Well DURATIONs of 0 were mentioned a little below that.
But it it worth clarifying in the option description itself.
So I'll make the following change:
-This option has no effect if @command{timeout}'s duration is 0 which
-disables the associated timeout.
+This option has no effect if either the main @var{duration}
+of the @command{timeout} command, or the @var{duration} specified
+to this option, is 0.
cheers,
Pádraig