Bug 30884 - bash attempts to bind termcap 'kH' to end-of-line, misses xterm End key
Summary: bash attempts to bind termcap 'kH' to end-of-line, misses xterm End key
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: readline   
(Show other bugs)
Version: 7.1
Hardware: i386
OS: Linux
Target Milestone: ---
Assignee: Preston Brown
QA Contact: David Lawrence
Depends On:
TreeView+ depends on / blocked
Reported: 2001-03-07 00:18 UTC by Bill Crawford
Modified: 2007-04-18 16:32 UTC (History)
0 users

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2001-03-07 23:41:37 UTC
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

Description Bill Crawford 2001-03-07 00:18:30 UTC
readline uses the termcap interface by default.

It attempts to bind the termcap capabilities 'kh' and 'kH' to
beginning-of-line and end-of-line functions in readline.  However for
xterm, the End key is defined in terminfo.src (in the ncurses package) as
'kend' => termcap '@7' ...

There are two possible fixes for this: change the terminfo.src file to use
'kll' instead of 'kend' or hack readline to check for the '@7' capability
as well.

Changing the terminfo source isn't really an option as bash and other
readline-based CLIs would still not work correctly on other platforms (I
use Solaris a lot, too).

Since this fails to work correctly on other platforms (specifically, bash
doesn't correctly bind end-of-line on Solaris 6 through 8 either) I would
like to see a fix for this that could be fed back to the readline
maintainers.  I'll do that myself if I have to, but a fix in RH7.1 would at
least get rid of the current /etc/inputrc bandaid.

Comment 1 Bill Crawford 2001-03-07 23:41:33 UTC
I apologise for the confusing subject line.  The problem originally arose in
relation to bash, but I traced it to a "feature" of the readline library.  In
fact it's more of a historical misunderstanding.

Comment 2 Preston Brown 2001-03-09 04:58:03 UTC
agreed that readline should be fixed.  kH is entirely wrong.

fixed in -8 and later.

Comment 3 Preston Brown 2001-03-09 04:59:24 UTC
one more comment: most likely we never noticed this because the default
/etc/inputrc we ship takes care of all these things, and it masks the
compiled-in behaviour.

Comment 4 Bill Crawford 2001-03-09 10:00:35 UTC
Yes, it used to be masked.  I've noticed for the last year plus that it doesn't
work right on "the other Un*x" :)
Much appreciated.

Although ... the xterm terminfo doesn't work right with Solaris xterm ...

Note You need to log in before you can comment on or make changes to this bug.