Should find traverse symbolic links?
George Robbins
grr at cbmvax.commodore.com
Tue Feb 26 07:04:36 AEST 1991
In article <1991Feb25.130613.2553 at phri.nyu.edu> roy at alanine.phri.nyu.edu (Roy Smith) writes:
>
> I was surprised to observe today that if you do "find dir ..." and
> dir is a symbolic link to a directory, the directory isn't entered. Thus:
>
> This seems to me to be The Wrong Thing. Is it a bug in find, or
> was it really intended to work that way?
It seems questionable but I'd think there'd be a lot more problems if
if did follow links - symlink loops lurk everywhere, not to mention
links in user modifiable directories pointing into system stuff to
trap the unwary root.
For the initial case of the argument being a symlink, you can probably
use the "find /link/" trailing slash kludge, as long as you expect it's
going to be a link to a directory or a directory..
--
George Robbins - now working for, uucp: {uunet|pyramid|rutgers}!cbmvax!grr
but no way officially representing: domain: grr at cbmvax.commodore.com
Commodore, Engineering Department phone: 215-431-9349 (only by moonlite)
More information about the Comp.unix.wizards
mailing list