Subject: Re: CVS commit: src/usr.bin/find
To: None <firstname.lastname@example.org>
From: Christos Zoulas <email@example.com>
Date: 10/22/2005 19:08:32
In article <20051022071528.GA698@antioche.eu.org>,
Manuel Bouyer <firstname.lastname@example.org> wrote:
>> That particular one is easy to fix; they appear to do something like:
>> if (path ends with a slash)
>> printf("%s%s\n", path, rest);
>> printf("%s/%s\n", path, rest);
>> But that is a special case, it is not path normalization which they don't do.
>> They are not really trimming trailing slashes or anything. We can do the same
>In this example, if /usr/share is a symlink pointing to some other directory,
>find /usr/share/ will follow it, while find /usr/share will not:
>baladeur# cd /tmp/
>baladeur# ln -s /usr/share .
>baladeur# find /tmp/share -name Berlin
>baladeur# find /tmp/share/ -name Berlin
>Stripping the trailing slash in find may cause a change in behavior in this
>case, but I don't know if it's a real problem or not (find /tmp/share/. would
>still work ok).
I am not stripping any trailing slash, I am just not printing an extra one
if one exists.