Summary: | app-shells/bash-4.2_p24: pattern substitution fails with extglob option and UTF-8 locale (was: app-admin/eselect-1.3.1: bug in apply_text_highlights function) | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | Vadim A. Misbakh-Soloviov (mva) (RETIRED) <mva> |
Component: | [OLD] Core system | Assignee: | Gentoo's Team for Core System packages <base-system> |
Status: | RESOLVED FIXED | ||
Severity: | major | CC: | eselect |
Priority: | Normal | Keywords: | REGRESSION |
Version: | unspecified | ||
Hardware: | All | ||
OS: | Linux | ||
URL: | http://lists.gnu.org/archive/html/bug-bash/2012-04/msg00134.html | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- |
Description
Vadim A. Misbakh-Soloviov (mva) (RETIRED)
![]() *libs/output.bash ;) This seems to be a regression in bash-4.2_p24. The problem occurs if the string contains UTF-8 characters and if the extglob shell option is set: $ LC_ALL=en_US.UTF-8 $ shopt -s extglob First try with ASCII only, works as expected: $ text="aaabbb" $ echo "${text} ${text//?aa} ${text//\aaa}" aaabbb bbb bbb But it fails with UTF-8: $ text="aaaäöü" $ echo "${text} ${text//?aa} ${text//\aaa}" aaaäöü aaaäöü aaaäöü Without extglob, it appears to work properly again: $ shopt -u extglob $ echo "${text} ${text//?aa} ${text//\aaa}" aaaäöü äöü äöü I don't see the problem with bash-4.1_p11. Reassigning to base-system. moved upstream then as 4.1 works but 4.2 fails Patch available (2nd answer), so what we prefer to do now? Waiting for release of new version in upstream or add a patch? ;) i'm going to wait to see what Chet says Chet OK-ed it, so i've added it to 4.2_p24-r1 |