Fix for broken tabstops on AT&T Sys V/386
Steve Friedl
friedl at mtndew.Tustin.CA.US
Sat Sep 22 13:55:09 AEST 1990
Hi folks,
There is a bug in AT&T System V/386 Release 3.2 (and
probably others) where the final console tabstop doesn't work.
If you have a file containing the following (pretend column
numbers start at zero):
8 16 24 32 40 48 56 64 72
v v v v v v v v v
with tabs between, the final "72 v" will appear at the start of
the following line. Vi and other programs depending on tabs will
fail miserably, and the workaround has been to do `stty tab3' to
have the driver do tab expansion (don't try this in ksh because
*it* does tabs right).
The big bummer is when working remotely with cu. The OTHER
end has to have the `stty tab3', and I really hate to transmit 8
spaces instead of one tab, especially when working at 1200bps --
I have one customer like this :-(
/usr/include/sys/at_ansi.h contains a "struct ansistate"
that has (among other things) a list of tabstops, but I could
never find any kind of ioctl that would give me access to it.
After digging around, I found that I can get at this struct by
poking around in /dev/kmem and have now fixed the problem so that
tabs work the right way. I've been running this for a couple of
weeks now and am totally delighted with the fix.
I have no idea if this is broken on other versions of UNIX,
but I have fixed it on my machine. Before I post the source to this
I would like to have others suffering from this problem give my
code a try first. Those interested should send me mail and
I'll send you the code.
Steve
--
Stephen J. Friedl, KA8CMY / I speak for me only / Tustin, CA / 3B2-kind-of-guy
+1 714 544 6561 / friedl at mtndew.Tustin.CA.US / {uunet,attmail}!mtndew!friedl
Jesse Helms for U.S. Supreme Court Justice
More information about the Comp.unix.sysv386
mailing list