summaryrefslogtreecommitdiffstats
path: root/usr.bin
diff options
context:
space:
mode:
authortjr <tjr@FreeBSD.org>2002-07-22 05:35:59 +0000
committertjr <tjr@FreeBSD.org>2002-07-22 05:35:59 +0000
commitb8007ee7a0c2979b4081be1289dfbcc81743446a (patch)
tree84d29cd8027d9958e7d884415e68d0d4e991ffea /usr.bin
parent7be639a7c001f8dc5f8e7b6d1951845156bb997d (diff)
downloadFreeBSD-src-b8007ee7a0c2979b4081be1289dfbcc81743446a.zip
FreeBSD-src-b8007ee7a0c2979b4081be1289dfbcc81743446a.tar.gz
Correct syntax error, remove the unescaped newline between "||" and the
command it is intended to test. pdksh and bash caught this syntax error, sh(1) did not behave as intended. PR: 40386
Diffstat (limited to 'usr.bin')
-rw-r--r--usr.bin/locate/locate/mklocatedb.sh6
1 files changed, 2 insertions, 4 deletions
diff --git a/usr.bin/locate/locate/mklocatedb.sh b/usr.bin/locate/locate/mklocatedb.sh
index fb743e4..39d15d7 100644
--- a/usr.bin/locate/locate/mklocatedb.sh
+++ b/usr.bin/locate/locate/mklocatedb.sh
@@ -76,16 +76,14 @@ if [ X"$1" = "X-presort" ]; then
$code $bigrams > $filelist || exit 1
locate -d $filelist / | $bigram | $sort -nr | head -128 |
- awk '{if (/^[ ]*[0-9]+[ ]+..$/) {printf("%s",$2)} else {exit 1}}' > $bigrams
- || exit 1
+ awk '{if (/^[ ]*[0-9]+[ ]+..$/) {printf("%s",$2)} else {exit 1}}' > $bigrams || exit 1
locate -d $filelist / | $code $bigrams || exit 1
exit
else
if $sortcmd $sortopt > $filelist; then
$bigram < $filelist | $sort -nr |
- awk '{if (/^[ ]*[0-9]+[ ]+..$/) {printf("%s",$2)} else {exit 1}}' > $bigrams
- || exit 1
+ awk '{if (/^[ ]*[0-9]+[ ]+..$/) {printf("%s",$2)} else {exit 1}}' > $bigrams || exit 1
$code $bigrams < $filelist || exit 1
else
echo "`basename $0`: cannot build locate database" >&2
OpenPOWER on IntegriCloud