Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

RE: Trap and exit



> > #! /bin/sh
> > trap 'echo trap: $?' 0
> > exit 59
> > /tmp % ash ./foo.sh
> > trap: 59
>
> It looks like a bug in Zsh. Quoting Unix 98:
>

OTOH both sh and ksh here behave the same as Zsh. Unless there are
compatibility reasons, I still prefer sh/bash.

-andrej



Messages sorted by: Reverse Date, Date, Thread, Author