find(1): Is this a bug or not?
Bakul Shah
bakul at bitblocks.com
Tue Nov 30 15:54:23 UTC 2010
On Tue, 30 Nov 2010 12:33:54 +0100 =?utf-8?Q?Dag-Erling_Sm=C3=B8rgrav?= <des at des.no> wrote:
> Bakul Shah <bakul at bitblocks.com> writes:
> > Index: function.c
> > --- function.c (revision 212707)
> > +++ function.c (working copy)
> > @@ -560,7 +560,7 @@
> > empty = 1;
> > dir = opendir(entry->fts_accpath);
> > if (dir == NULL)
> > - err(1, "%s", entry->fts_accpath);
> > + return 0;
> > for (dp = readdir(dir); dp; dp = readdir(dir))
> > if (dp->d_name[0] != '.' ||
> > (dp->d_name[1] != '\0' &&
>
> You should replace the err() call with a warn() call instead of removing
> it outright.
That would print the err msg twice as opendir (or something)
already seems to report the error. Try it!
More information about the freebsd-hackers
mailing list