From bernd@heitec.net  Mon Jun 19 16:32:52 2000
Return-Path: <bernd@heitec.net>
Received: from heitec.net (paladin.heitec.net [212.204.92.251])
	by hub.freebsd.org (Postfix) with ESMTP id AB43037B8E5
	for <FreeBSD-gnats-submit@freebsd.org>; Mon, 19 Jun 2000 16:32:45 -0700 (PDT)
	(envelope-from bernd@heitec.net)
Received: (from bernd@localhost)
	by  heitec.net (8.9.3/8.9.3) id BAA00995;
	Tue, 20 Jun 2000 01:33:03 +0200 (CEST)
	(envelope-from bernd)
Message-Id: <200006192333.BAA00995@ heitec.net>
Date: Tue, 20 Jun 2000 01:33:03 +0200 (CEST)
From: bdluevel@heitec.net
Sender: bernd@heitec.net
Reply-To: bdluevel@heitec.net
To: FreeBSD-gnats-submit@freebsd.org
Subject: bash prompt problem, or perhaps curses problem
X-Send-Pr-Version: 3.2

>Number:         19388
>Category:       misc
>Synopsis:       bash prompt problem, or perhaps curses problem
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-bugs
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Mon Jun 19 16:40:01 PDT 2000
>Closed-Date:    Sun Jul 16 02:30:53 PDT 2000
>Last-Modified:  Mon Jun  4 14:10:01 PDT 2001
>Originator:     Bernd Luevelsmeyer
>Release:        FreeBSD 4.0-STABLE i386
>Organization:
Heitec AG
>Environment:

	FreeBSD 4.0-Stable as of 2000-06-19

>Description:

	If you have escape sequences in a bash prompt, and execute
	several long commands (longer than one line) so that they
	are in the history buffer, and then press cursor-up and
	cursor-down to change between these commands, the prompt
	may be messed up and the displayed command lines too.

>How-To-Repeat:

	I assume you are in a bash shell (port shells/bash2), in a
	cons50 terminal with 80 columns.
	
	a) Get a prompt with escape sequences:
	    export PS1='\[\e[7m\]hello\[\e[m\]'
	b) Get suitable command into the history:
	    ab ab ab ab ab ab ... ab
	   (That is so many 'ab' groups that the last 'b' is in the
	    second row exactly under the first 'l' of the prompt)
	c) Get second command so you've got something to change:
	    cd cd cd cd cd cd ... cd
	   (Make it the same length, so the last 'd' is also
	    below the first 'l' of the prompt)
	d) Press cursor-up and cursor-down so you change between
	   these two commands in bash's history. Watch the prompt.

>Fix:

	Do not have escape sequences in the prompt.


>Release-Note:
>Audit-Trail:

From: Doug Barton <DougB@gorean.org>
To: bdluevel@heitec.net
Cc: FreeBSD-gnats-submit@freebsd.org
Subject: Re: misc/19388: bash prompt problem, or perhaps curses problem
Date: Sun, 25 Jun 2000 16:22:43 -0700

 bdluevel@heitec.net wrote:
 
 >         If you have escape sequences in a bash prompt, and execute
 >         several long commands (longer than one line) so that they
 >         are in the history buffer, and then press cursor-up and
 >         cursor-down to change between these commands, the prompt
 >         may be messed up and the displayed command lines too.
 
 	If you are not already, please try Bash 2.04. There were several
 improvements in ANSI escape sequence handling. If you are having
 additional problems after upgrading, please use bash-bug to report them.
 This is a Bash problem, not a FreeBSD one. 
 
 Good luck,
 
 Doug
 

From: Bernd Luevelsmeyer <bernd.luevelsmeyer@heitec.net>
To: FreeBSD-gnats-submit@freebsd.org
Cc: Doug Barton <DougB@gorean.org>
Subject: Re: misc/19388: bash prompt problem, or perhaps curses problem
Date: Mon, 26 Jun 2000 05:44:37 +0200

 Doug Barton wrote:
 [...]
 >         If you are not already, please try Bash 2.04. There were several
 >  improvements in ANSI escape sequence handling. If you are having
 >  additional problems after upgrading, please use bash-bug to report them.
 >  This is a Bash problem, not a FreeBSD one.
 [...]
 
 I was indeed using Bash 2.03. I have now updated to 2.04 and the problem
 has not changed.
 
 The same effect happens on NetBSD 1.4.2 (bash 2.03 there); so, unless
 they have the same curses-or-whatever bug, it's indeed a bash problem. I
 will report to bashbug.
 
 Thanks,
 	B. Luevelsmeyer
 

From: Bernd Luevelsmeyer <bernd.luevelsmeyer@heitec.net>
To: freebsd-gnats-submit@FreeBSD.org, bdluevel@heitec.net
Cc:  
Subject: Re: misc/19388: bash prompt problem, or perhaps curses problem
Date: Sun, 16 Jul 2000 09:01:47 +0200

 I mailed to 'bug-bash@gnu.org' on 26 Jun 2000 but didn't get an answer.
 As far as I'm concerned, please close the PR. I consider this to be a
 bash problem.
 
State-Changed-From-To: open->closed 
State-Changed-By: dwmalone 
State-Changed-When: Sun Jul 16 02:30:53 PDT 2000 
State-Changed-Why:  
Submitter says this is a bash problem. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=19388 

From: Bernd Luevelsmeyer <bdluevel@heitec.net>
To: freebsd-gnats-submit@FreeBSD.org
Cc:  
Subject: Re: misc/19388: bash prompt problem, or perhaps curses problem
Date: Mon, 04 Jun 2001 23:04:36 +0200

 Steve Kettle mailed me to ask about the state about this old (and
 closed) problem, and much to my surprise I found it's gone now. I don't
 know when it vanished. I can't reproduce it anywhere.
 The oldest system I've got access to is a 4.2-Stable from Jan 4 2001 and
 has a bash "GNU bash, version 2.04.0(1)-release (i386--freebsd4.1.1)",
 and there it's gone too.
 
 Greetings,
 	B. Luevelsmeyer
>Unformatted:
