From: Herbert Xu <herbert@gondor.apana.org.au>
To: DASH Mailing List <dash@vger.kernel.org>
Subject: [PATCH] shell: Disable fnmatch by default
Date: Sun, 19 May 2024 22:36:19 +0800 [thread overview]
Message-ID: <ZkoOY9cWtv09aDjg@gondor.apana.org.au> (raw)
As fnmatch(3) is terribly slow with multi-byte strings, disable
it by default.
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
diff --git a/configure.ac b/configure.ac
index 50effc0..338d5bd 100644
--- a/configure.ac
+++ b/configure.ac
@@ -37,8 +37,8 @@ if test "$enable_static" = "yes"; then
export LDFLAGS="-static"
fi
-AC_ARG_ENABLE(fnmatch, AS_HELP_STRING(--disable-fnmatch, \
- [Do not use fnmatch(3) from libc]))
+AC_ARG_ENABLE(fnmatch, AS_HELP_STRING(--enable-fnmatch, \
+ [Use fnmatch(3) from libc]))
AC_ARG_ENABLE(glob, AS_HELP_STRING(--enable-glob, [Use glob(3) from libc]))
dnl Checks for libraries.
@@ -122,7 +122,7 @@ if test "$enable_test_workaround" = "yes"; then
[Define if your faccessat tells root all files are executable])
fi
-if test "$enable_fnmatch" != no; then
+if test "$enable_fnmatch" = yes; then
use_fnmatch=
AC_CHECK_FUNCS(fnmatch, use_fnmatch=yes)
fi
--
Email: Herbert Xu <herbert@gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
reply other threads:[~2024-05-19 14:36 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=ZkoOY9cWtv09aDjg@gondor.apana.org.au \
--to=herbert@gondor.apana.org.au \
--cc=dash@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox