From xemacs-m  Fri Mar 28 10:49:58 1997
Received: from canker.atype.com (jsc@canker.atype.com [137.103.200.167])
	by xemacs.org (8.8.5/8.8.5) with ESMTP id KAA06426
	for <xemacs-beta@xemacs.org>; Fri, 28 Mar 1997 10:49:57 -0600 (CST)
Received: (from jsc@localhost)
	by canker.atype.com (8.8.5/8.8.5) id LAA23815;
	Fri, 28 Mar 1997 11:50:00 -0500
Date: Fri, 28 Mar 1997 11:50:00 -0500
Message-Id: <199703281650.LAA23815@canker.atype.com>
From: "Jin S. Choi" <jsc@atype.com>
To: xemacs-beta@xemacs.org
Subject: gnuattach and terminal state
Reply-to: jsc@atype.com
Mime-Version: 1.0 (generated by tm-edit 7.105)
Content-Type: text/plain; charset=US-ASCII

I reported earlier that using gnuattach screws up my terminal state.
I spent some time tracing through the tty init and reset functions in
sysdep.c. As far as I can tell, it appears to be resetting the
terminal to the correct state; it uses tcsetattr with the same values
it had before frobbing them in tty_init_sys_modes_on_device. The
following tcgetattr shows that it took effect. My terminal is still
screwed up.

Does anyone have any idea of what might be going on? Or is even
experiencing the same problem? One effect of this is that ocrnl gets
turned off, so 'ls' gives that diagonal listing effect.

I've resorted to using this, but I would like to see it fixed for real 
eventually.

#!/bin/sh
sttystate=`stty -g`
gnuattach $*
stty $sttystate

