Ralph Corderoy <[EMAIL PROTECTED]> writes:
> I wasn't clear. I realise it isn't always an absolute path, and is
> normally whatever's passed to execve(2). I was just trying to point out
> that some old Unixes, Xenix? -- I can't remember, effectively strip any
> path, absolute or relative, from execve's argument before it turns up in
> argv[0], i.e. execve("./ls", ...) and execve("/bin/ls", ...) both
The first argument of execve is irrelevant for argv[0]. The argv array
(including argv[0]) is completely passed in by the caller, which can set
it any way it likes. What you have seen might be the effect of a
misbehaving shell. Usually argv[0] is the command name before looking it
up in $PATH.
Andreas.
--
Andreas Schwab, SuSE Labs, [EMAIL PROTECTED]
SuSE Linux AG, Maxfeldstra�e 5, 90409 N�rnberg, Germany
Key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5
"And now for something completely different."
_______________________________________________
Autoconf mailing list
[EMAIL PROTECTED]
http://lists.gnu.org/mailman/listinfo/autoconf