bugs in trap signal handling

2012-10-10 Thread lanshun zhou
Red Hat Enterprise Linux Server release 6.2 (Santiago) uname -r: 2.6.32-220.17.1.el6.x86_64 bash version: bash-4.1.2-9.el6_2.src.rpm (also tested with bash-4.2 compiled from source with patches bash42-001~bash42-037) When interrupt_immediately is set, handler for signals registered by trap

bugs in trap signal handling

2012-10-10 Thread lanshun zhou
Red Hat Enterprise Linux Server release 6.2 (Santiago) uname -r: 2.6.32-220.17.1.el6.x86_64 bash version: bash-4.1.2-9.el6_2.src.rpm (also tested with bash-4.2 compiled from source with patches bash42-001~bash42-037) When interrupt_immediately is set, handler for signals registered by trap

Re: bugs in trap signal handling

2012-10-10 Thread Chet Ramey
On 10/10/12 2:53 AM, lanshun zhou wrote: > Red Hat Enterprise Linux Server release 6.2 (Santiago) > uname -r: 2.6.32-220.17.1.el6.x86_64 > bash version: bash-4.1.2-9.el6_2.src.rpm (also tested with bash-4.2 > compiled from source > with patches bash42-001~bash42-037) > > When interrupt_imme

Re: different exit codes in $? and ${PIPESTATUS[@]}

2012-10-10 Thread Andreas Schwab
Wladimir Sidorenko writes: > Dear all, > > After running the following command: > > $ ! test 0 -eq 0 > > I can see different exit codes in $? and ${PIPESTATUS[@]}. Here, what I get > > $ ! test 1 -eq 0 ; echo $? ${PIPESTATUS[@]} > 0 1 > > $ ! test 0 -eq 0 ; echo $? ${PIPESTATUS[@]} > 1 0 > > I'd