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

Re: local_traps doesn't restore traps set from functions



On Thu, May 7, 2020 at 11:21 PM Daniel Shahaf <d.s@xxxxxxxxxxxxxxxxxx> wrote:
>
> The following patch fixes it:

Thanks for the patch. I confirm that it works. I've tried a handful of
different combinations of traps and all work as expected.

One stylistic suggestion for the patch: replace sigtrapped[i] fixup with this:

    sigtrapped[i] -= 1 << ZSIG_SHIFT;

It'll align the code with the preceding comment to the point of making
the comment superfluous. I also find it easier to understand although
that may be subjective.

Roman.



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