This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH v3] [BZ #14579] rtld: limit self loading check to normal mode only
> If script relies upon -e behavior, then 'set -e' is preferable. However,
> the current glibc practice is $(SHELL) -e:
That doesn't make it a good idea.
> set -e makes the script exit with a non-zero status if something goes
> wrong. Not the program being tested but something else. I think
> it is a good default behavior for test scripts.
I know what it does. I can't see how it would make any possible difference
in your script, which doesn't run anything other than the tested program.
> > $rtld $rtld 2>&1
> > test $? -le 127 || result=1
>
> No, the exit status has to be saved anyway because its value is needed for
> two different actions: print and test.
OK, then rc=$? before test $rc.