Path: utzoo!utgpu!jarvis.csri.toronto.edu!rutgers!tut.cis.ohio-state.edu!tds.kth.se!juha From: juha@tds.kth.se (Juha Sarlin) Newsgroups: gnu.bash.bug Subject: fix to stop rl_insert from loosing a character Message-ID: <8909041152.AA03640@ttds.tds.kth.se> Date: 4 Sep 89 13:52:10 GMT Sender: daemon@tut.cis.ohio-state.edu Distribution: gnu Organization: GNUs Not Usenet Lines: 30 rl_insert() in bash 1.03 has some code to insert many characters at once. In the rare cases when this code is run it looses the original inargument. Here is my fix: *** /tmp/,RCSt1a04042 Mon Sep 4 13:40:57 1989 --- readline.c Mon Sep 4 13:38:49 1989 *************** *** 2135,2143 **** if (chars_avail) { ! int slen, key = 0, i = 0; char *string = (char *)xmalloc (slen = 20); while (chars_avail--) { key = rl_getc (in_stream); --- 2135,2144 ---- if (chars_avail) { ! int slen, key = 0, i = 1; char *string = (char *)xmalloc (slen = 20); + string[0] = c; while (chars_avail--) { key = rl_getc (in_stream); -- Juha Sarlin juha@tds.kth.se