From 4c8c67c444a0c81a8a1939a75fedeeaa35909ba2 Mon Sep 17 00:00:00 2001 From: Paul Eggert Date: Wed, 29 Jan 2025 20:02:25 -0800 Subject: [PATCH] Document AIX 7.3 find exec + bug MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit * doc/autoconf.texi (Limitations of Usual Tools): Document AIX 7.3 bug with exit status of ‘find ... -exec ... +’. --- doc/autoconf.texi | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/doc/autoconf.texi b/doc/autoconf.texi index 07794561e..8dffd02c1 100644 --- a/doc/autoconf.texi +++ b/doc/autoconf.texi @@ -19358,6 +19358,13 @@ $ @kbd{find . -name foo -exec echo '@{@}-@{@}' \;} while GNU @command{find} reports @samp{./foo-./foo}. POSIX allows either behavior. +AIX 7.3 @samp{find ... -exec @var{command} +} incorrectly fails if +@var{command} is not executed. For example, @samp{find . -name '*.tmp' +-exec rm @{@} +} incorrectly outputs a diagnostic and fails if no file +names end in @samp{.tmp}. To work around this problem you can use a +circumlocution like @samp{find . -name '*.tmp' -exec rm -f @{@} + -o +-exec true ';'}. + @anchor{grep} @item @command{grep} @c ----------------- -- 2.47.3