+++ This bug was initially created as a clone of Bug #241647 +++
[This is a problem with readline compiled into bash; I chose to file it against
readline, hoping that its maintainer might know how to fix it. ;-]
Description of problem:
The cursor position is wrong after serach in commandline history.
Version-Release number of selected component (if applicable):
$ rpm -q bash && bash --version
GNU bash, version 3.1.17(1)-release (i686-redhat-linux-gnu)
Steps to Reproduce:
3. ctrl-R (start incremental search backwards)
4. ctrl-G (cancel it)
The cursor shall be positioned just after the prompt text.
The cursor is positioned on letter `m' in the middle of the prompt text
Note that my PS1 contains a non-printing control sequence; it is enclosed in
\[...\] pair, to tell readline about it. With C locale, this mechanism works,
but it seems it does not work with utf-8 locales.
Actually the cursor is positioned 13 characters to the left from the correct
position. And 13 is the length of the non-printing sequence in the prompt. I
have tried a shorter non-printing sequence and again, the skew was equal to its
-- Additional comment from email@example.com on 2007-05-29 07:42 EST --
Upstream has released a patch that fixes this issue.
-- Additional comment from firstname.lastname@example.org on 2007-06-05 09:19 EST --
Thanks a lot! I hope comment #1 will help the bash maintainer.
This request was evaluated by Red Hat Product Management for
inclusion in a Red Hat Enterprise Linux release. Since this
bugzilla is in a component that is not approved for the current
release, it has been closed with resolution deferred. You may
reopen this bugzilla for consideration in the next release.
This is upstream's bash32-016 patch.
This request was evaluated by Red Hat Product Management for inclusion in a Red
Hat Enterprise Linux maintenance release. Product Management has requested
further review of this request by Red Hat Engineering, for potential
inclusion in a Red Hat Enterprise Linux Update release for currently deployed
products. This request is not yet committed for inclusion in an Update
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on the solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.