[pacman-dev] [PATCH 09/10] makepkg: Clear ERR trap before trying to restore it

Jan Alexander Steffens jan.steffens at gmail.com
Mon Jun 4 11:15:26 UTC 2018


On Mon, Jun 4, 2018 at 1:05 PM Allan McRae <allan at archlinux.org> wrote:

> On 04/06/18 18:47, Jan Alexander Steffens wrote:
> > The ERR trap is not inherited by functions unless the "errtrace" option
> > is set. So in the current situation, makepkg's internal functions are
> > supposed to do manual error checking. Bad returns from function calls at
> > the top level will trigger the trap, though.
> >
>
> Is there any point to the restoretrap variable then?


Probably not. I don't think we nest run_function_safe calls. Then again, it
doesn't hurt, either.


More information about the pacman-dev mailing list