This is the mail archive of the
libc-alpha@sources.redhat.com
mailing list for the glibc project.
Re: Realpath & context sensitive symlinks
- To: Paul Eggert <eggert at twinsun dot com>
- Subject: Re: Realpath & context sensitive symlinks
- From: Michael Eager <eager at mvista dot com>
- Date: Thu, 27 Sep 2001 12:22:52 -0700
- CC: libc-alpha at sourceware dot cygnus dot com
- Organization: MontaVista Software, Inc.
- References: <3BB372A6.D33CBCEE@mvista.com> <200109271857.f8RIvBs02755@shade.twinsun.com>
Paul Eggert wrote:
>
> > Date: Thu, 27 Sep 2001 11:40:38 -0700
> > From: Michael Eager <eager@mvista.com>
> >
> > Anyone got a solution to this? Or suggestions?
>
> Realpath could invoke the 'resolvepath' system call, if it is available.
> That would be more reliable than the chdir/getcwd hack that you suggested.
>
> This assumes that your kernel has 'resolvepath'. If it doesn't,
> perhaps you could have it added. It does seem to be a better approach.
>
> Solaris 8 realpath uses 'resolvepath'.
Unfortunately, it doesn't appear that Linux has resolvepath.
--
Michael Eager eager@mvista.com 408-328-8426
MontaVista Software, Inc. 1237 E. Arques Ave., Sunnyvale, CA 94085