Fix BRE typos in check-safety.sh

* manual/check-safety.sh: Fix BRE portability typos.
POSIX says \] produces undefined results.
This commit is contained in:
Paul Eggert 2022-09-14 00:10:45 -05:00
parent 2d7ed98add
commit 05967faf0e
1 changed files with 3 additions and 3 deletions

View File

@ -109,15 +109,15 @@ success=false
# optional comment about exclusions is between []s at the end of the
# line.
grep -n '^@c \+[^@ ]\+\( dup\)\?'\
'\( @\(mt\|a[sc]\)[^ ]*\)*\( \[.*\]\)\?$' "$@" |
'\( @\(mt\|a[sc]\)[^ ]*\)*\( \[.*]\)\?$' "$@" |
grep -v ':@c *[^@{}]*\( @mt[^ {}]*\)*'\
'\( @as[^ {}]*\)*\( @ac[^ {}]*\)*\( \[.*\]\)\?$' &&
'\( @as[^ {}]*\)*\( @ac[^ {}]*\)*\( \[.*]\)\?$' &&
success=false
# Check that comments containing safety remarks do not contain
# duplicate remarks.
grep -n '^@c \+[^@ ]\+\( dup\)\?'\
'\( @\(mt\|a[sc]\)[^ ]*\)*\( \[.*\]\)\?$' "$@" |
'\( @\(mt\|a[sc]\)[^ ]*\)*\( \[.*]\)\?$' "$@" |
grep '[^:]\(@\(mt\|a[sc]\)[^ ]*\) \(.*[^:]\)\?\1\($\| \)' &&
success=false