On Wed, Nov 24, 2010 at 01:26:04PM -0500, der Mouse wrote:
 > > Right. But if you want a guaranteed absolute path you should be able
 > > to do it by calling getcwd first.
 > 
 > Only if you accept breakage if the current directory no longer has any
 > name.

Well, if you can't call getcwd, then it won't work... (I was not
suggesting that the getcwd call be wedged inside namei)

 > Of course, if you consider that acceptable, then fine.  I don't, not
 > for something as central as namei (though this looks as though you may
 > be talking about only certain filesystems, in which case it may be
 > acceptable).

We'll probably end up doing it on every exec, since there's currently
no way to tell from the ELF headers whether $ORIGIN needs to be set
(this should be considered a bug) but failure is ok for that. In
compat_svr4 I doubt anyone cares much if it fails in corner cases.

-- 
David A. Holland
dholl...@netbsd.org

Reply via email to