GNU bug report logs - #6308
Preserve command exit code in timeout(3)

Previous Next

Package: coreutils;

Reported by: "Ángel González" <keisial <at> gmail.com>

Date: Sun, 30 May 2010 00:23:01 UTC

Severity: normal

Tags: moreinfo

Done: Pádraig Brady <P <at> draigBrady.com>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Thomas Krennwallner <tkren <at> kr.tuwien.ac.at>
To: Pádraig Brady <P <at> draigBrady.com>
Cc: Ángel González <keisial <at> gmail.com>, Jim Meyering <jim <at> meyering.net>, 6308 <at> debbugs.gnu.org
Subject: bug#6308: Preserve command exit code in timeout(3)
Date: Mon, 29 Oct 2012 09:34:49 +0100
On Mon Oct 29, 2012 12:43:27AM +0000, Pádraig Brady wrote:
> On 10/22/2012 01:27 PM, Thomas Krennwallner wrote:
> >On Mon Oct 22, 2012 10:20:14AM +0100, Pádraig Brady wrote:
> >>On 10/21/2012 09:36 PM, Thomas Krennwallner wrote:
> >[...]
> >>>I'm thus very interested into seeing timeout --exit-status.
> >>
> >>Ok cool.
> >>
> >>It's tempting to support this without an option.
> >>I.E. for all commands that exit without WIFSIGNALED being set,
> >>i.e. for all commands that catch and exit on signal reception.
> >>However that wouldn't work in general I think due to cascading
> >>timeout commands or commands that catch signals for cleanup etc.,
> >>though I suppose the latter case might be catered for by
> >>specifying a specific signal with the -s option.
> >
> >Yes, I completely agree.  And would only make a difference for programs
> >that carry on meaning with their exit code, i.e., where the code depends
> >on the computation, as described in my use case.  The default use is
> >IMHO just error exit in programs, and most have it implemented this way
> >(think of clean-up at signal reception).  Having a default exit code of
> >124 is good for those standard programs.
> >
> >>So I'll look at adding this new option right after the
> >>imminent 8.20 release.
> >
> >Thank you, this sounds like good news!
> 
> Proposed patch is attached.

I've tried it and it works flawlessly.  Thank you!

Best,
TK

-- 
Thomas Krennwallner
University assistant
.
TU Wien - Vienna University of Technology
Institute of Information Systems
Favoritenstrasse 9-11, 1040 Wien, Austria
.
T: +43 1 58801 18469   F: +43 1 58801 918469
tkren AT kr DOT tuwien DOT ac DOT at
http://www.kr.tuwien.ac.at/staff/tkren/
.
DVR: 0005886




This bug report was last modified 12 years and 253 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.