PATCH: replacing exec*p with BB_EXEC*P

Gabriel L. Somlo somlo at cmu.edu
Sun Feb 4 13:47:37 UTC 2007


On Sun, Feb 04, 2007 at 11:28:53AM +0100, Bernhard Fischer wrote:
> >Twenty one callsites. Maybe BB_EXECVP should call bb_execvp()
> >(which should be a function) to save space?
> 
> Yes, please put it into an bb_execvp

OK, will do that. Now, about the specifics: I could simply do what the
macro now does, i.e., check for the existance of a busybox applet and
then call execvp. Or, I could "unwind" execvp, and check for the
presence of a '/' in the program name first, then for the presence of
an applet, and last search PATH the way the real execvp does, and end
up by calling execve(), the way the real execvp does.

Do we want to keep it simple more than we care about speed (avoiding
work when the progname contains a '/') ?

Cheers,
Gabriel



More information about the busybox mailing list