[13348] in Athena Bugs
curses library
daemon@ATHENA.MIT.EDU (bcb@MIT.EDU)
Tue Mar 21 04:17:03 1995
From: bcb@MIT.EDU
Date: Tue, 21 Mar 95 04:16:58 -0500
To: bugs@MIT.EDU
Looking at source for the BSD4.4 version of curses (which isn't the one
implemented on athena), I've found where the problem would lie. In that
code, "initscr" calls "setterm," which sets various terminal parameters.
Unfortunately, "setterm" gets the window-size parameters with:
ioctl(STDERR_FILENO, TIOCGWINSZ, &win)
Which tells it the size of the window stderr is writing to, not the size of
the window *it*'s going to write to. initscr then immediately uses this
value to initialize memory and so on, so correcting LINES and COLS after
initscr returns isn't good enough -- curses remains convinced that the
window is the size of stderr's tty.
Unfortunately compiling a fixed version of setterm didn't fix the problem,
for the simple reason that my new version never got called. Apparently the
curses implemented on athena uses a different name for its equivalent
procedure. So, the only way I can fix this, as far as I can see, is to
compile a complete new curses from source, which I'd really rather not do.
Can you do anything at your end?
Brian