Bug 92372

Summary: readline crashes when "5" is pressed with numlock off
Product: [Retired] Red Hat Linux Reporter: Need Real Name <lethalwp>
Component: readlineAssignee: Tim Waugh <twaugh>
Status: CLOSED RAWHIDE QA Contact: Jay Turner <jturner>
Severity: high Docs Contact:
Priority: medium    
Version: 9CC: bhelf, rdieter, srevivo
Target Milestone: ---   
Target Release: ---   
Hardware: i386   
OS: Linux   
Fixed In Version: 4.3-7 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2003-06-25 09:32:55 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Description Need Real Name 2003-06-05 15:47:43 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.2.1) Gecko/20030225

Description of problem:
when a program uses readline, if you press the key "5" on an azerty belgian
keyboard on the numeric part, with numlock off, readline enters in a recursive
loop finally segfaulting:

here's a stacktrace when used with lftp 2.6.3, bu it also happens with for
instance bc, pftp, smbclient, ...

(gdb) info stack
#0  0x40036795 in _rl_dispatch_subseq () from /usr/lib/libreadline.so.4
#1  0x4003677e in _rl_dispatch () from /usr/lib/libreadline.so.4
#2  0x40036803 in _rl_dispatch_subseq () from /usr/lib/libreadline.so.4
#3  0x4003677e in _rl_dispatch () from /usr/lib/libreadline.so.4
#209527 0x4003677e in _rl_dispatch () from /usr/lib/libreadline.so.4
#209528 0x40036803 in _rl_dispatch_subseq () from
#209529 0x4003677e in _rl_dispatch () from /usr/lib/libreadline.so.4
#209530 0x40036af9 in _rl_dispatch_subseq () from
#209531 0x40036ab4 in _rl_dispatch_subseq () from
#209532 0x4003677e in _rl_dispatch () from /usr/lib/libreadline.so.4
#209533 0x400364d0 in readline_internal_char () from
#209534 0x40036695 in readline_internal_char () from
#209535 0x400366ce in readline_internal_char () from
#209536 0x4003619f in readline () from /usr/lib/libreadline.so.4
#209537 0x080693fb in lftp_readline ()
#209538 0x08067042 in ReadlineFeeder::NextCmd(CmdExec*, char const*) (
    this=0x80f0b40, exec=0x80e74e8, prompt=0x80ea020 "lftp :~> ")
    at lftp.cc:133
#209539 0x0806bc43 in CmdExec::Do() ()
#209540 0x0807f8f5 in SMTask::Schedule() ()
#209541 0x0806632c in WaitDone(CmdExec*) (exec=0x80e74e8) at lftp.cc:73
#209542 0x08066a12 in main (argc=1, argv=0xbfffe564) at lftp.cc:377
#209543 0x420156a4 in __libc_start_main () from /lib/tls/libc.so.6

recursive loop? ;)  (and be prepared to press <enter> a long time in
---Type <return> to continue, or q <return> to quit--- grrggrg =)

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
1. lftp or any other program using libreadline
2. press 5 with numlock off
3. it has segfaulted

Actual Results:  segfault

Expected Results:  nothing should happen

Additional info:

Comment 1 Tim Waugh 2003-06-24 15:10:48 UTC
Which console are you using?  Looks similar to bug #97937.

Comment 2 Need Real Name 2003-06-24 17:30:16 UTC
i'm using Eterm 0.9.2-1, it doesn't do it under xterm, neither rxvt, neither
text console, probably because of the keymapping?

i can attach my slightly modified inputrc if you want, but  i don't think this
is important
(basically i've only added "\eOc": forward-word
"\eOd": backward-word
 for my Eterm :) )

anyway i've mailed the readline gnu development team and they've answered:

> So i've recompiled readline 4.3, tried with LD_LIBRARY_PATH, and the
> same problem happens

This has been fixed for months.


Comment 3 Tim Waugh 2003-06-25 09:32:55 UTC
Thanks for the pointer to the patch.  Fixed package will appear in rawhide shortly.

Comment 4 Tim Waugh 2003-12-13 23:22:07 UTC
*** Bug 112048 has been marked as a duplicate of this bug. ***