James Youngman 7e3d7a273f Don't issue an error message twice for the same target file.
* find/defs.h (struct state): New member,
already_issued_stat_error_msg, used to de-duplicate error
messages.  If it is true, we already issued an error message for
the current target file.
Declare fatal_target_file_error, fatal_nontarget_file_error,
nonfatal_target_file_error, nonfatal_nontarget_file_error.
Between them, they replace fatal_file_error and
nonfatal_file_error.  The *target_file_error versions are
de-duplicated and the nontarget_file_error_versions are not.
* find/util.c (nonfatal_nontarget_file_error): Implement.
(fatal_nontarget_file_error): Implement.
(nonfatal_target_file_error): Implement.
(fatal_target_file_error): Implement.
(fatal_file_error): Remove.
(nonfatal_file_error): Remove.
(error_severity): Define error_severity (moved from ftsfind.c)
(get_statinfo): Call nonfatal_target_file_error in order to avoid
a duplicate message.  ALso call error_severity after a different
call to error to preserve the constraint that we exit with a
nonzero status if we issue a diagnostic.
(cleanup): Call nonfatal_nontarget_file_error instead of
nonfatal_file_error.
* find/ftsfind.c (error_severity): Move to util.c.
* find/tree.c (build_expression_tree): Initialise
state.already_issued_stat_error_msg.
* find/find.c (main): Initialise state.already_issued_stat_error_msg.
(wd_sanity_check): Call fatal_target_file_error instead of
fatal_file_error.
(chdir_back): Call fatal_nontarget_file_error instead of
fatal_file_error.
(process_path): Initialise state.already_issued_stat_error_msg.
* find/ftsfind.c (consider_visiting): Call
nonfatal_target_file_error instead of calling error directly.
(find): Call error_severity to ensure exit status is nonzero after
a call to error.
(main): Initialise state.already_issued_stat_error_msg.
* find/parser.c (collect_arg_stat_info): Call
fatal_target_file_error instead of fatal_file_error.
(parse_newerXY): Likewise.
(parse_samefile): Likewise.
(parse_samefile): Likewise.
(open_output_file): Call fatal_nontarget_file_error instead of
fatal_file_error.
* find/pred.c (checked_fprintf): Likewise.
(checked_print_quoted): Likewise.
(checked_fwrite): Likewise.
(checked_fflush): Likewise.
* find/sharefile.c (entry_free): Likewise.

Signed-off-by: James Youngman <jay@gnu.org>
2010-04-06 22:50:15 +01:00
2010-04-06 01:03:40 +01:00
2010-04-03 12:22:57 +01:00
2010-04-06 01:03:40 +01:00
2010-04-02 01:47:10 +01:00
2010-04-02 01:47:10 +01:00
2010-04-03 12:22:57 +01:00
1999-08-08 19:52:01 +00:00
2007-08-19 15:31:38 +00:00
2009-03-07 21:22:36 +00:00

This package contains the GNU find, xargs, and locate programs.  find
and xargs comply with POSIX 1003.2, as far as I know (with the
exception of the "+" modifier for the "-exec" action, which isn't
implemented yet).  They also support a large number of additional
options, some borrowed from Unix and some unique to GNU.

See the file NEWS for a list of major changes in the current release.

See the file INSTALL for compilation and installation instructions.

To verify the GPG signature of the release, you will need the public
key of the findutils maintainer.  You can download this from
ftp://ftp.gnu.org/gnu/gnu-keyring.gpg.  Alternatively, you could query
a PGP keyserver, but you will need to use one that can cope with
subkeys containing photos.  Many older key servers cannot do this.  I
use subkeys.pgp.net.  I think that one works.  See also the
"Downloading" section of http://www.gnu.org/software/findutils/.

Special configure options:

--with-afs
  Make find support "-fstype afs".  Requires /afs, /usr/afsws/lib, and
/usr/afsws/include.  configure doesn't add AFS support
automatically because it adds considerably to find's size, and the
AFS libraries need -lucb on Solaris, which breaks find.

--enable-id-cache
  Make tables of used UIDs and GIDs at startup instead of using
getpwuid or getgrgid when needed.  Speeds up -nouser and -nogroup
unless you are running NIS or Hesiod, which make password and group
calls very expensive.

--enable-debug
  Produce output on the standard error output indicating what find is
doing.  This information includes details about how the command line
has been parsed and what files have been stat()ed.  This output is
normally interesting only to the maintainer, and so is off by default.

DEFAULT_ARG_SIZE=<value>
  If this environment variable is defined to a numeric expression
during configure, it determines the default argument size limits used
by xargs without -s, and by find, when spawning child processes.
Otherwise, the default is set at 128 kibibytes.  If the system cannot
support the default limit, the system's limit will be used instead.


To gain speed, GNU find avoids statting files whenever possible.
It does this by:
1. Checking the number of links to directories and not statting files
that it knows aren't directories until it encounters a test or action
that needs the stat info.
2.  Rearranging the command line, where possible, so that it can do tests
that don't require a stat before tests that do, in hopes that the
latter will be skipped because of an OR or AND.  (But it only does
this where it will leave the output unchanged.)

The locate program and its helper programs are derived (heavily
modified) from James Woods' public domain fast-find code, which is
also distributed with the 4.3BSD find.  Because POSIX.2 requires `find
foo' to have the same effect as `find foo -print', the fast-find
searching has been moved to a separate program, `locate'; the same
thing has been done in 4.4BSD.  If you use locate, you should run the
included `updatedb' script from cron periodically (typically nightly).

Mail suggestions and bug reports for these programs to
bug-findutils@gnu.org.
Description
Mirror from GNU Savannah.
Readme 14 MiB
Languages
C 55.2%
Shell 14.4%
Roff 11.2%
Logos 9.6%
Makefile 4.7%
Other 4.9%