[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Findutils-patches] Change request proposal for a new Find functiona
Re: [Findutils-patches] Change request proposal for a new Find functionality
Mon, 8 Nov 2010 10:15:47 +0000
[ Removing address@hidden from CC: and adding
On Sat, Nov 6, 2010 at 6:08 PM, Michel Lanne <address@hidden> wrote:
> Good morning,
> This mail just to mention a simple lacking functionality in the Find
> There is no way to disable the warning messages sent on the error
> output, and especially the "Permission non granted" error message sent
> for each unaccessible directory met during the research process.
> The alone way proposed on various docs or sites is to redirect the
> error output on /dev/null. OK, thank's, but that's far to be great.
> This is even an invitation to very bad programming, especially by
> avoiding the ability to choose through the find parameters the
> warnings which are suppressed and those which are not.
> So, I submit to the Find maintainers the idea of a change request for
> this functionality, maybe through a new option.
If such a change were ever to be made, it would have to be a new option,
since the POSIX standard requires the current behaviour.
The POSIX standard requires both the diagnostic message and the resulting
non-zero exit status (
*CONSEQUENCES OF ERRORS*The CONSEQUENCES OF ERRORS section describes the
effects on the environment, file systems, process state, and so on, when
error conditions occur. It does not describe error messages produced or exit
status values used.
The many reasons for failure of a utility are generally not specified by the
utility descriptions. Utilities may terminate prematurely if they encounter:
invalid usage of options, arguments, or environment variables; invalid usage
of the complex syntaxes expressed in EXTENDED DESCRIPTION sections;
difficulties accessing, creating, reading, or writing files; or difficulties
associated with the privileges of the process.
The following shall apply to each utility, unless otherwise stated:
If the requested action cannot be performed on an operand representing a
file, directory, user, process, and so on, the utility shall issue a
diagnostic message to standard error and continue processing the next
operand in sequence, but the final exit status shall be returned as
For a utility that recursively traverses a file hierarchy (such as
or *chown* <../utilities/chown.html> *-R*), if the requested action
cannot be performed on a file or directory encountered in the hierarchy, the
utility shall issue a diagnostic message to standard error and continue
processing the remaining files in the hierarchy, but the final exit status
shall be returned as non-zero.
If the requested action characterized by an option or option-argument
cannot be performed, the utility shall issue a diagnostic message to
standard error and the exit status returned shall be non-zero.
When an unrecoverable error condition is encountered, the utility shall
exit with a non-zero exit status.
A diagnostic message shall be written to standard error whenever an error
When a utility encounters an error condition several actions are possible,
depending on the severity of the error and the state of the utility.
Included in the possible actions of various utilities are: deletion of
temporary or intermediate work files; deletion of incomplete files; validity
checking of the file system or directory.
*Default Behavior:* When this section is listed as "Default.", it means that
any changes to the environment are unspecified.
The speicific decription of find (
http://www.opengroup.org/onlinepubs/009695399/utilities/find.html) does not
deviate from this:
CONSEQUENCES OF ERRORS
|[Prev in Thread]
||[Next in Thread]|
- Re: [Findutils-patches] Change request proposal for a new Find functionality,
James Youngman <=