forked from extern/shorewall_code
Quit find after finding the first newer file
Signed-off-by: Tom Eastep <teastep@shorewall.net>
This commit is contained in:
parent
550003f0f4
commit
e0a757ea03
@ -383,7 +383,7 @@ uptodate() {
|
||||
local ifs
|
||||
|
||||
if [ -n "$g_shorewalldir" ]; then
|
||||
if [ -n "$(find ${dir} -maxdepth 1 -type f -newer $1)" ]; then
|
||||
if [ -n "$(find ${dir} -maxdepth 1 -type f -newer $1 -print -quit)" ]; then
|
||||
return 1;
|
||||
fi
|
||||
fi
|
||||
@ -393,7 +393,7 @@ uptodate() {
|
||||
|
||||
for dir in $CONFIG_PATH; do
|
||||
if [ -n "$dir" ]; then
|
||||
if [ -n "$(find ${dir} -maxdepth 1 -type f -newer $1)" ]; then
|
||||
if [ -n "$(find ${dir} -maxdepth 1 -type f -newer $1 -print -quit)" ]; then
|
||||
IFS="$ifs"
|
||||
return 1;
|
||||
fi
|
||||
|
Loading…
Reference in New Issue
Block a user