From 59736620fe412be363535f6836d9109100d5bd98 Mon Sep 17 00:00:00 2001 From: Tom Eastep Date: Mon, 15 Apr 2024 21:15:38 -0700 Subject: [PATCH] busybox 'find' now supports -quit so use it if the installed version supports that option Signed-off-by: Tom Eastep --- Shorewall/lib.cli-std | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/Shorewall/lib.cli-std b/Shorewall/lib.cli-std index 4dd0e8149..8ff7de7f4 100644 --- a/Shorewall/lib.cli-std +++ b/Shorewall/lib.cli-std @@ -382,20 +382,18 @@ uptodate() { local dir local find - local quit + local quit=-quit local maxdepth find=$(mywhich find) [ -n "${find}" ] || return 1 - if [ -h "${find}" ]; then + if [ -h "${find}" ] && ! qt ${find} . -name foo -print -quit ; then # - # 'Find' is provided by Busybox and doesn't support -quit. + # 'Find' is provided by Busybox and this old versions don't support -quit. # quit= - else - quit=-quit fi if [ "$AUTOMAKE" = recursive ]; then