Subject: misc/4124: termcap "amiga" entry problems
To: None <gnats-bugs@gnats.netbsd.org>
From: None <tsarna@endicor.com>
List: netbsd-bugs
Date: 09/19/1997 16:02:42
>Number:         4124
>Category:       misc
>Synopsis:       termcap "amiga" entries have problems
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    misc-bug-people (Misc Bug People)
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Fri Sep 19 14:05:02 1997
>Last-Modified:
>Originator:     Ty Sarna
>Organization:
	Endicor Technologies, Inc., San Antonio, Texas
>Release:        1.2G-970901
>Environment:

System: NetBSD lotharon.endicor.com 1.2G NetBSD 1.2G (LOTHARON) #2: Sat Sep 13 15:07:31 CDT 1997 tsarna@lotharon.endicor.com:/usr/src/sys/arch/sun3/compile/LOTHARON sun3


>Description:
	"amiga" termcap doesn't work with IW225/AS225 telnet and rlogin
>How-To-Repeat:
	Use the telnet or rlogin clients in IW225 or AS225 (the TCP/IP
	package by Commodore, now sold by Interworks). Connect to a
	NetBSD machine, and see a garbled display.
>Fix:
	Apply diffs below, and forward to termcap maintainers (I asked
	them about some of this, but haven't heard anything back yet).

	These patches:
		- Restore Kent Polk's termcap entry as "amiga". It
		  works, has worked, and will work, so I don't see
		  why the other version replaced it. The other one
		  uses the \233 CSI, which saves a byte but breaks
		  in some cases, especially with {IW|AS}225
		  {telnet|rlogin}. Kent's, on the other hand, was
		  actually included in {AS|IW}225. This makes it
		  the only Amiga termcap ever shipped by C=, to my
		  knowlegde, and thus the closest thing to an
		  "official" one. :-)
		- Fix various bugs introduced by the termcap maintainers
		  into Kent's termcap. Compared with the "1.4" termcap
		  Kent sent me, our version (which claims to be based on
		  1.4) is missing '[' fom the CSI in the codes for arrow
		  and function keys. It also has r1 instead of rs,
		  though termcap(5) says r1 is for terminfo and
		  rs is for termcap. There are some other differences,
		  including some undocumented capabilities(?),
		  but so far it works fine with just these mods.

*** termcap.src.orig	Wed Sep 17 21:44:13 1997
--- termcap.src	Fri Sep 19 15:42:51 1997
***************
*** 9787,9809 ****
  # :k0=\E9~:	map F10 to k0 - could have F0-9 -> k0-9, but ... F10 was 'k;'
  # (amiga: removed obsolete :kn#10:,
  # also added empty <acsc> to suppress a warning --esr)
! amiga-old|Amiga ANSI:\
  	:am:bs:bw:xn:\
  	:co#80:li#24:\
  	:AL=\E[%dL:DC=\E[%dP:DL=\E[%dM:DO=\E[%dB:IC=\E[%d@:\
  	:LE=\E[%dD:RI=\E[%dC:SF=\E[%dS:SR=\E[%dT:UP=\E[%dA:ac=:\
  	:ae=^O:al=\E[L:as=^N:bl=^G:bt=\E[Z:cd=\E[J:ce=\E[K:\
  	:cl=\E[H\E[J:cm=\E[%i%d;%dH:dc=\E[P:dl=\E[M:do=\E[B:ei=:\
! 	:ho=\E[H:ic=\E[@:im=:is=\E[20l:k0=\E9~:k1=\E0~:k2=\E1~:\
! 	:k3=\E2~:k4=\E3~:k5=\E4~:k6=\E5~:k7=\E6~:k8=\E7~:k9=\E8~:\
! 	:kb=^H:kd=\EB:kl=\ED:kr=\EC:ku=\EA:le=\E[D:mb=\E[7;2m:\
  	:md=\E[1m:me=\E[m:mh=\E[2m:mk=\E[8m:mr=\E[7m:nd=\E[C:\
! 	:r1=\Ec:se=\E[m:sf=\E[S:so=\E[7m:sr=\E[T:ue=\E[m:up=\E[A:\
  	:us=\E[4m:ve=\E[ p:vi=\E[0 p:
  
  # From: Hans Verkuil <hans@wyst.hobby.nl>, 4 Dec 1995
  # (amiga: added empty <acsc> to suppress a warning --esr)
! amiga|Amiga ANSI:\
  	:bs:bw:ms:\
  	:co#80:li#24:\
  	:DC=\233%dP:DO=\233%dB:IC=\233%d@:LE=\233%dD:RI=\233%dC:\
--- 9787,9809 ----
  # :k0=\E9~:	map F10 to k0 - could have F0-9 -> k0-9, but ... F10 was 'k;'
  # (amiga: removed obsolete :kn#10:,
  # also added empty <acsc> to suppress a warning --esr)
! amiga|Amiga ANSI:\
  	:am:bs:bw:xn:\
  	:co#80:li#24:\
  	:AL=\E[%dL:DC=\E[%dP:DL=\E[%dM:DO=\E[%dB:IC=\E[%d@:\
  	:LE=\E[%dD:RI=\E[%dC:SF=\E[%dS:SR=\E[%dT:UP=\E[%dA:ac=:\
  	:ae=^O:al=\E[L:as=^N:bl=^G:bt=\E[Z:cd=\E[J:ce=\E[K:\
  	:cl=\E[H\E[J:cm=\E[%i%d;%dH:dc=\E[P:dl=\E[M:do=\E[B:ei=:\
! 	:ho=\E[H:ic=\E[@:im=:is=\E[20l:k0=\E[9~:k1=\E[0~:k2=\E[1~:\
! 	:k3=\E[2~:k4=\E[3~:k5=\E[4~:k6=\E[5~:k7=\E[6~:k8=\E[7~:k9=\E[8~:\
! 	:kb=^H:kd=\E[B:kl=\E[D:kr=\E[C:ku=\E[A:le=\E[D:mb=\E[7;2m:\
  	:md=\E[1m:me=\E[m:mh=\E[2m:mk=\E[8m:mr=\E[7m:nd=\E[C:\
! 	:rs=\Ec:se=\E[m:sf=\E[S:so=\E[7m:sr=\E[T:ue=\E[m:up=\E[A:\
  	:us=\E[4m:ve=\E[ p:vi=\E[0 p:
  
  # From: Hans Verkuil <hans@wyst.hobby.nl>, 4 Dec 1995
  # (amiga: added empty <acsc> to suppress a warning --esr)
! amiga-bad|Amiga ANSI:\
  	:bs:bw:ms:\
  	:co#80:li#24:\
  	:DC=\233%dP:DO=\233%dB:IC=\233%d@:LE=\233%dD:RI=\233%dC:\
>Audit-Trail:
>Unformatted: