Bug 74383 - start of line is discarded when writing a prompt
start of line is discarded when writing a prompt
Product: Red Hat Linux
Classification: Retired
Component: bash (Show other bugs)
i386 Linux
medium Severity medium
: ---
: ---
Assigned To: Tim Waugh
Ben Levenson
: 80319 86058 (view as bug list)
Depends On:
  Show dependency treegraph
Reported: 2002-09-22 18:08 EDT by Miloslav Trmac
Modified: 2007-04-18 12:46 EDT (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2002-11-04 06:41:52 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2003:140 normal SHIPPED_LIVE Updated bash packages fix several bugs 2003-06-23 00:00:00 EDT

  None (edit)
Description Miloslav Trmac 2002-09-22 18:08:03 EDT
Version-Release number of selected component (if applicable):

Sometime between 7.3 and (null), bash started to return to the start of a
line before writing its prompt, which is confusing, unexpected and discards
potentially-very-hard-to-get-again information (I have spent 10 minutes
figuring out why "rpm -q --qf '%{ARCH}' kernel" gave no output, but what
if I forget the last "\n" in last printf of a two-weeks-running program?).

Steps to Reproduce:
1. open gnome-terminal
2. insert "echo -n foo"
3. insert "echo -n 012345678901234567890123456789"

Actual Results:
[mitr@localhost mitr]$ echo -n foo
[mitr@localhost mitr]$ echo -n 012345678901234567890123456789
[mitr@localhost mitr]$ 3456789

Expected Results:
[mitr@localhost mitr]$ echo -n foo
foo[mitr@localhost mitr]$ echo -n 012345678901234567890123456789
012345678901234567890123456789[mitr@localhost mitr]$
Comment 1 Miloslav Trmac 2002-10-05 20:01:36 EDT
Same in 8.0.

Note that this does occurr in gnome-terminal, xterm and konsole,
but *not* on a virtual terminal.

Note also that in gnome-terminal and the two other, backspacing
though accented characters in UTF-8 is OK, but on a virtual
terminal it moves to the left too much; this might have the same
Comment 2 Tim Waugh 2002-10-07 10:31:16 EDT
Yes, I've seen it too and it's annoying.
Comment 3 Need Real Name 2002-11-04 06:41:45 EST
It's not limited to builtins; the same happens for /usr/bin/printf for example.
It has nothing to do with PROMPT_COMMAND (unsetting it does not correct the
It is not related to $TERM (using e.g. linux as TERM does not correct the problem).
Using 'echo -n foo; sleep 2' clearly shows the cursor at the start of the line
Comment 4 Tim Waugh 2002-12-03 05:23:40 EST
Fixed package is bash-2.05b-12, which will shortly appear in rawhide.
Comment 5 Tim Waugh 2002-12-24 07:52:24 EST
*** Bug 80319 has been marked as a duplicate of this bug. ***
Comment 6 Tim Waugh 2003-03-13 05:39:11 EST
*** Bug 86058 has been marked as a duplicate of this bug. ***
Comment 7 Tim Waugh 2003-06-23 10:52:18 EDT
An errata 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.


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