bug-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: return bultin ignores explicit exit value when used in DEBUG trap


From: Chet Ramey
Subject: Re: return bultin ignores explicit exit value when used in DEBUG trap
Date: Thu, 26 Nov 2015 17:44:01 -0500
User-agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.11; rv:38.0) Gecko/20100101 Thunderbird/38.3.0

On 11/19/15 2:06 AM, Grisha Levit wrote:
> Not sure if this is a documentation bug or a functional one, but the man page 
> does not seem to agree with the observed behavior for return when invoked in 
> DEBUG traps.

Thanks for the report.  The internal trap handler used for DEBUG and other
signals the shell treats specially needed to pick up the argument supplied
to `return' as well as noting `return' was called.

This affects the DEBUG, RETURN, and ERROR traps.

Chet
-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
                 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, ITS, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/



reply via email to

[Prev in Thread] Current Thread [Next in Thread]