NetBSD Problem Report #28402

From pavel.cahyna@st.mff.cuni.cz  Tue Nov 23 20:49:27 2004
Return-Path: <pavel.cahyna@st.mff.cuni.cz>
Received: from mail.casablanca.cz (mail.casablanca.cz [82.208.31.182])
	by narn.netbsd.org (Postfix) with ESMTP id 4DFAA252232
	for <gnats-bugs@gnats.netbsd.org>; Tue, 23 Nov 2004 20:49:25 +0000 (UTC)
Message-Id: <1101243384.0@pc.martani.n2.repy.czf>
Date: Tue, 23 Nov 2004 20:56:24 -0000
From: "Pavel Cahyna" <pavel.cahyna@st.mff.cuni.cz>
To: "gnats bugs" <gnats-bugs@netbsd.org>
Subject: reset command does not work (termcap problem)
X-Send-Pr-Version: gtk-send-pr 0.4 
X-GNATS-Notify:

>Number:         28402
>Category:       misc
>Synopsis:       reset command does not work (termcap problem)
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    misc-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Tue Nov 23 20:51:03 +0000 2004
>Closed-Date:    
>Last-Modified:  Sat Jan 06 15:20:01 +0000 2007
>Originator:     Pavel Cahyna
>Release:        NetBSD 2.0_BETA i386
>Organization:
>Environment:


System: NetBSD 2.0_BETA (GENERIC_DIAGNOSTIC s patchem D. Reeda - PR#26839) #4: Wed Oct  6 10:13:10 CEST 2004
	pavel@pc.martani.n2.repy.czf:/mnt/obj/kompilace/jadra/compile/GENERIC_DIAGNOSTIC



>Description:


if a console program crashes, the reset command is supposed to get the terminal to a 
clean state, but it fails to do so in both xterm and wscons. What it does is to output 
the "rs" sequence, but many terminal types (including wsvt25, vt220 and xterm) don't 
have such sequence defined. Some (as the vt220) have only "r2" sequence, which is 
terminfo only, and more, this doesn't work either even if renamed to "rs". 

Terminfo on linux has rs1, rs2 and rs3. rs1 seems to do the job on xterm (where it is defined
as Esc c), but not on vt220 (where it is Esc   [   ?   3   l).


>How-To-Repeat:


to simulate the effect of a crashed application, type tput vi. The cursor disappears.
Now type reset in an attempt to restore it. Nothing happens. ssh to a linux host and type 
reset there. The cursor is restored properly (in xterm, not in wscons, here even reset on 
linux fails).


>Fix:


find the hard reset strings in ttys documentation and add them as the rs capability
to /usr/share/misc/termcap.
For both xterm and wscons, adding rs=\Ec works (this is rs1 in the linux terminfo entry for 
xterm). According to the xterm documentation
(ftp://invisible-island.net/xterm/ctlseqs.txt.gz), this escape sequence should be standard
on DEC ttys, but I do not have any VT100 to test it.


>Release-Note:

>Audit-Trail:
From: Thomas Dickey <dickey@his.com>
To: gnats-bugs@netbsd.org
Cc: 
Subject: re: misc/28402
Date: Sun, 28 Nov 2004 11:40:37 -0500 (EST)

 The hard-reset \Ec is standard on VT100's and up, but DECSTR (VT220's and
 up) is preferred.

 -- 
 Thomas E. Dickey
 http://invisible-island.net
 ftp://invisible-island.net

From: Pavel Cahyna <pcah8322@artax.karlin.mff.cuni.cz>
To: gnats-bugs@NetBSD.org
Cc: Thomas Dickey <dickey@his.com>
Subject: Re: misc/28402: reset command does not work (termcap problem)
Date: Tue, 30 Nov 2004 23:04:31 +0100

 I can confirm that DECSTR (ESC[!p) works both in wscons and in xterm.

From: Pavel Cahyna <pcah8322@artax.karlin.mff.cuni.cz>
To: gnats-bugs@NetBSD.org
Cc: Thomas Dickey <dickey@his.com>
Subject: Re: misc/28402: reset command does not work (termcap problem)
Date: Thu, 2 Dec 2004 09:34:18 +0100

 > I can confirm that DECSTR (ESC[!p) works both in wscons and in xterm.
 And also on my VT510, while ESC c resets it completely, making it forget
 which serial port is the line to computer and which is the printer.

From: Thomas Dickey <dickey@his.com>
To: Pavel Cahyna <pavel.cahyna@st.mff.cuni.cz>
Cc: gnats-bugs@NetBSD.org
Subject: Re: misc/28402: reset command does not work (termcap problem)
Date: Thu, 2 Dec 2004 04:34:27 -0500 (EST)

 On Thu, 2 Dec 2004, Pavel Cahyna wrote:

 >> I can confirm that DECSTR (ESC[!p) works both in wscons and in xterm.
 > And also on my VT510, while ESC c resets it completely, making it forget
 > which serial port is the line to computer and which is the printer.

 That reminds me - it would be nice to get another check of the wrap-margin
 tests I added to vttest this summer (that's one of the screens from the
 first menu item).

  	http://invisible-island.net/vttest/

 (yes I should have my own vtXXX terminal, but I'd have nowhere to put it).

 -- 
 Thomas E. Dickey
 http://invisible-island.net
 ftp://invisible-island.net

From: Thomas Klausner <wiz@netbsd.org>
To: gnats-bugs@NetBSD.org
Cc: 
Subject: PR/28402 CVS commit: src/share/termcap
Date: Sat,  6 Jan 2007 14:24:42 +0000 (UTC)

 Module Name:	src
 Committed By:	wiz
 Date:		Sat Jan  6 14:24:42 UTC 2007

 Modified Files:
 	src/share/termcap: termcap.src

 Log Message:
 From Sergey Svishchev in PR 34995:
 Current termcap entry for wsvt25 is 'micro-minimal', so here's an
 updated one.  I've based it on vt220-8.  DECSCNM sequence (dark/light
 background) is not emulated by wscons, so visual bell is disabled (vb@);
 also, I think that 'xn' quirk is unnecessary.  'rs' sequence should
 fix PR/28402.

 I've also added kB (back tab), F1 (F11 key) and F2 (F12 key) to xterm
 entry.


 To generate a diff of this commit:
 cvs rdiff -r1.97 -r1.98 src/share/termcap/termcap.src

 Please note that diffs are not public domain; they are subject to the
 copyright notices on the relevant files.

State-Changed-From-To: open->feedback
State-Changed-By: wiz@netbsd.org
State-Changed-When: Sat, 06 Jan 2007 14:26:17 +0000
State-Changed-Why:
Is it still there? The patch in 34995 suggested it
included a fix.


State-Changed-From-To: feedback->open
State-Changed-By: wiz@netbsd.org
State-Changed-When: Sat, 06 Jan 2007 15:15:27 +0000
State-Changed-Why:
Feedback supplied.


From: Pavel Cahyna <pavel.cahyna@matfyz.cz>
To: gnats-bugs@NetBSD.org
Cc: misc-bug-people@netbsd.org, netbsd-bugs@netbsd.org,
	gnats-admin@netbsd.org, wiz@netbsd.org
Subject: Re: misc/28402 (reset command does not work (termcap problem))
Date: Sat, 6 Jan 2007 16:14:03 +0100

 On Sat, Jan 06, 2007 at 02:26:18PM +0000, wiz@netbsd.org wrote:
 > Synopsis: reset command does not work (termcap problem)
 > 
 > State-Changed-From-To: open->feedback
 > State-Changed-By: wiz@netbsd.org
 > State-Changed-When: Sat, 06 Jan 2007 14:26:17 +0000
 > State-Changed-Why:
 > Is it still there? The patch in 34995 suggested it
 > included a fix.

 The patch in 34995 could fix it only for wsvt25.

>Unformatted:

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.39 2013/11/01 18:47:49 spz Exp $
$NetBSD: gnats_config.sh,v 1.8 2006/05/07 09:23:38 tsutsui Exp $
Copyright © 1994-2007 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.