]> git.plutz.net Git - shellwiki/commitdiff
bugfix: search engine wordsplitting in busybox awk
authorPaul Hänsch <paul@plutz.net>
Mon, 14 Oct 2024 22:21:24 +0000 (00:21 +0200)
committerPaul Hänsch <paul@plutz.net>
Mon, 14 Oct 2024 22:21:24 +0000 (00:21 +0200)
parsers/40_indexer.sh

index 56a8990bd89e2bbd3a9d2e6f8a5f65aa6de23c87..b16449bf643d6315e4f2cd25ec6781548952ae41 100755 (executable)
@@ -39,9 +39,9 @@ done \
 | awk '
   BEGIN { # Field separator FS should include punctuation, including Unicode Block U+2000 - U+206F
           if ( length("¡") == 1 )  # Utf-8 aware AWK
-          FS = "([] \\t\\n\\r!\"#'\''()*+,./:;<=>?\\\\^_`{|}~[-]|%[0-9A-Fa-f]{2}|'"$(printf '[\342\200\200-\342\201\257]')"')+";
+          FS = "([] \t\n\r!\"#'\''()*+,./:;<=>?\\\\^_`{|}~[-]|%[0-9A-Fa-f]{2}|'"$(printf '[\342\200\200-\342\201\257]')"')+";
           else                     # UTF-8 Hack
-          FS = "([] \\t\\n\\r!\"#'\''()*+,./:;<=>?\\\\^_`{|}~[-]|%[0-9A-Fa-f]{2}|'"$(printf '\342\200[\200-\277]|\342\201[\201-\257]')"')+";
+          FS = "([] \t\n\r!\"#'\''()*+,./:;<=>?\\\\^_`{|}~[-]|%[0-9A-Fa-f]{2}|'"$(printf '\342\200[\200-\277]|\342\201[\201-\257]')"')+";
           fi
         }
         { for (n = 1; n <= NF; n++) {