diff options
-rw-r--r-- | NEWS | 10 | ||||
m--------- | gnulib | 0 | ||||
-rwxr-xr-x | tests/word-delim-multibyte | 10 |
3 files changed, 20 insertions, 0 deletions
@@ -2,6 +2,16 @@ GNU grep NEWS -*- outline -*- * Noteworthy changes in release ?.? (????-??-??) [?] +** Bug fixes + + Some uses of \b in the C locale and with the DFA matcher would fail, e.g., + the following would print nothing (it should print the input line): + echo 123-x|LC_ALL=C grep '.\bx' + Using a multibyte locale, using certain regexp constructs (some ranges, + backreferences), or forcing use of the PCRE matcher via --perl-regexp (-P) + would avoid the bug. + [bug introduced in grep 2.3] + * Noteworthy changes in release 3.2 (2018-12-20) [stable] diff --git a/gnulib b/gnulib -Subproject b823b5dc51510ba59dd0d00d677070b9a2e1180 +Subproject 5d6a3cdd5c312e77a6d0f0848e3cb79a52e0865 diff --git a/tests/word-delim-multibyte b/tests/word-delim-multibyte index 0bc0e333..7d2c433c 100755 --- a/tests/word-delim-multibyte +++ b/tests/word-delim-multibyte @@ -24,4 +24,14 @@ grep -w "$e_acute" in > out 2>err || fail=1 compare out in || fail=1 compare /dev/null err || fail=1 +# Also ensure that this works in both the C locale and that multibyte one. +# In the C locale, it failed due to a dfa.c regression in grep-3.2. +echo 123-x > in || framework_failure_ + +for locale in C en_US.UTF-8; do + LC_ALL=$locale grep '.\bx' in > out 2>err || fail=1 + compare out in || fail=1 + compare /dev/null err || fail=1 +done + Exit $fail |