Bash Version: 3.0
Patch Level: 0
Release Status: release
Description:
The POSIX standard says:
-- begin quote --
The trap command with no arguments shall write to standard output a list
of commands associated with each condition. The format shall be:
"trap -- %s %s ...\n", <action>, <condition> ...
The shell shall format the output, including the proper use of quoting,
so that it is suitable for reinput to the shell as commands that achieve
the same trapping results. For example:
save_traps=$(trap)
...
eval "$save_traps"
-- end quote --
This is not happening in bash-3.00:
Thanks, this has been fixed. You'll notice that this happens only with
the exit trap.
Chet