bug-bash
[Top][All Lists]
Advanced

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

Re: Bash does not follow POSIX when return is called during the action o


From: Chet Ramey
Subject: Re: Bash does not follow POSIX when return is called during the action of a trap
Date: Tue, 11 Mar 2014 23:58:41 -0400
User-agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.9; rv:24.0) Gecko/20100101 Thunderbird/24.3.0

On 3/10/14, 2:22 PM, Eduardo A. Bustamante López wrote:
> According to POSIX:
> 
> | The value of the special parameter '?' shall be set to n, an
> | unsigned decimal integer, or to the exit status of the last command
> | executed if n is not specified. If the value of n is greater than
> | 255, the results are undefined. When return is executed in a trap
> | action, the last command is considered to be the command that
> | executed immediately preceding the trap action.

Thanks for the report.  I know how to fix this, and I will make the change
for the next release.

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]