diff options
author | Bernhard Voelker <mail@bernhard-voelker.de> | 2021-08-22 18:41:17 +0200 |
---|---|---|
committer | Bernhard Voelker <mail@bernhard-voelker.de> | 2021-09-20 00:14:58 +0200 |
commit | 5768a03ddfb5e18b1682e339d6cdd24ff721c510 (patch) | |
tree | 9c7e587d8e43c2c655674245626787a97b252a0d /tests/find/many-dir-entries-vs-OOM.sh | |
parent | 2c56e00ec9d6a735b9054513a3842dad0ef73394 (diff) | |
download | findutils-5768a03ddfb5e18b1682e339d6cdd24ff721c510.tar.gz |
oldfind: remove
The FTS-based find is the default for a long time; oldfind has not been
installed since 4.5.18 (2015), and was only just used in tests.
* NEWS: Document the change.
* doc/find-maint.texi (Factor Out Repeated Code): Remove mentioning of
oldfind.
* find/.gitignore (/oldfind): Remove entry.
* find/Makefile.am (check_PROGRAMS): Remove.
(oldfind_SOURCES): Remove.
* find/defs.h (struct dir_id): Remove, it was only used in oldfind.c.
(symlink_handling): Likewise.
Adjust comments wrt oldfind otherwise.
* find/oldfind.c: Remove.
* find/testsuite/config/unix.exp: Remove the code to search for and
to run tests with oldfind.
* find/testsuite/find.posix/dotdotfiles.exp: Adjust comment.
* po/POTFILES.in (find/oldfind.c): Remove entry.
* tests/find/debug-missing-arg.sh: Remove run with oldfind.
* tests/find/exec-plus-last-file.sh: Likewise.
* tests/find/execdir-fd-leak.sh: Likewise.
* tests/find/many-dir-entries-vs-OOM.sh: Likewise.
* tests/find/name-lbracket-literal.sh: Likewise.
* tests/find/printf_escape_c.sh: Likewise.
* tests/find/printf_escapechars.sh: Likewise.
* tests/find/printf_inode.sh: Likewise.
* tests/find/refuse-noop.sh: Likewise.
* tests/find/type_list.sh: Likewise.
* tests/local.mk (built_programs): Remove oldfind from list.
Diffstat (limited to 'tests/find/many-dir-entries-vs-OOM.sh')
-rwxr-xr-x | tests/find/many-dir-entries-vs-OOM.sh | 22 |
1 files changed, 8 insertions, 14 deletions
diff --git a/tests/find/many-dir-entries-vs-OOM.sh b/tests/find/many-dir-entries-vs-OOM.sh index 8ab343f7..d2edb253 100755 --- a/tests/find/many-dir-entries-vs-OOM.sh +++ b/tests/find/many-dir-entries-vs-OOM.sh @@ -19,7 +19,7 @@ # along with this program. If not, see <https://www.gnu.org/licenses/>. . "${srcdir=.}/tests/init.sh"; fu_path_prepend_ -print_ver_ find oldfind +print_ver_ find # Mark as expensive. expensive_ @@ -77,18 +77,12 @@ cd .. # Create a small directory as reference to determine lower ulimit. mkdir dir2 && touch dir2/a dir2/b dir2/c || framework_failure_ -# We don't check oldfind, as it uses savedir, meaning that -# it stores all the directory entries. Hence the excessive -# memory consumption bug applies to oldfind even though it is -# not using fts. -for exe in find oldfind; do - # Determine memory consumption for the trivial case. - vm="$(get_min_ulimit_v_ ${exe} dir2 -fprint dummy)" \ - || skip_ "this shell lacks ulimit support" - - # Allow 35MiB more memory than above. - ( ulimit -v $(($vm + 35000)) && ${exe} dir >/dev/null ) \ - || { echo "${exe}: memory consumption is too high" >&2; fail=1; } -done +# Determine memory consumption for the trivial case. +vm="$(get_min_ulimit_v_ find dir2 -fprint dummy)" \ + || skip_ "this shell lacks ulimit support" + +# Allow 35MiB more memory than above. +( ulimit -v $(($vm + 35000)) && find dir >/dev/null ) \ + || { echo "memory consumption is too high" >&2; fail=1; } Exit $fail |