*BSD News Article 9999


Return to BSD News archive

Received: by minnie.vk1xwt.ampr.org with NNTP
	id AA6951 ; Fri, 15 Jan 93 10:39:50 EST
Newsgroups: comp.unix.bsd
Path: sserve!manuel.anu.edu.au!munnari.oz.au!metro!ipso!runxtsa!bde
From: bde@runx.oz.au (Bruce Evans)
Subject: Re: Why won't it listen 8N1? :(
Message-ID: <1993Jan17.082435.1546@runx.oz.au>
Organization: RUNX Un*x Timeshare.  Sydney, Australia.
References: <727039483snz@kram.demon.co.uk> <C0v34n.7H5@unx.sas.com>
Date: Sun, 17 Jan 93 08:24:35 GMT
Lines: 23

> As well, I would like any information anyone discovers relating
> to this... I *can* log in as E71 and do an stty to get to 8N1,
> but when I crank up vi (elvis), it plops me back into E71 during
> the editing session.  As well, after leaving it, the tty is
> "restored" to E71 instead of 8N1.

elvis "knows" that BSD doesn't have termios, so it uses the old sgttyb
interface.  In 386BSD, termios is the primary interface and sgttyb is
implemented by compatibility code in the kernel.  The compatibility
code doesn't work very well.  In particular, the CS8 flag (8 bits) tends
to get lost when you switch from raw mode to cooked or cbreak mode.
Andrew Chernov posted fixes that might help for this case.

> Apparently, felix@smoky.ikf.physik.uni-frankfurt.de has "hacked"
> (his words, not mine :-)) up a version of getty which does the
> right thing, it is available on ref.tfs.com in /usr/packages/getty.tar.Z.

Andrew's fixes don't help getty.  It clobbers the tty setting on purpose
by setting it from the fixed values in <sys/ttydefaults.h>.

Bruce
-- 
Bruce Evans  (bde@runx.oz.au)