pathexec_run(a, b, c);
strerr_dieexec(111, a);
is a reasonably common pattern in execline programs, and since
strerr_dieexec expands to a 11 argument function call (of
strerr_diesys), this ends up generating a lot of code. Provide a
helper to do these two calls.
That's actually a pretty good idea, I hadn't thought about the amount
of generated code when a function takes a lot of arguments. Do you have
measurements of the gains that the helper provides, for static execline
binaries for instance?
src/libstddjb/pathexec_run_or_die.c | 10 ++++++++++
I don't like the "or die" terminology much - it makes me think of Perl.
:)
A common C convention for "if foobar() fails then die" is "xfoobar".
Unless someone has a better idea, I'll add such a helper as
xpathexec_run
(and probably xpathexec0_run too).
Thanks for the suggestion,
--
Laurent