find bug, plus and PATCH for wwwdocs/bin/preprocess

Linus Torvalds torvalds@transmeta.com
Fri Aug 10 10:36:00 GMT 2001


In article < Pine.BSF.4.33.0108101056420.2079-100000@deneb.dbai.tuwien.ac.at > you write:
>The following invocations are equivalent under
>   GNU find 4.1 (Red Hat 6.2 as on gcc.gnu.org)
>   FreeBSD find (FreeBSD 4.3)
>   Solaris find (Solaris 2.8)
>but no under
>   GNU find 4.1.6 (SuSE 7.2)
>
>1. find . \( -name CVS -prune \) -o -type f
>2. find . \( -name CVS -prune \) -o -type f -print
>
>I thus changed the former to the latter for increased portability,
>though I'm tempted to think this is a bug (or at least a misfeature)
>in GNU find 4.1.6.

That's definitely a bug in GNU find (since fixed), but the patch looks
valid regardless - the find bug happens to be standard behaviour for
some old non-POSIX "find" binaries where the default action was to do
nothing. 

So it's not just a workaround for a bug, it also looks like a valid
portability fix for old systems.

			Linus



More information about the Gcc-patches mailing list