Subject: tgetnum - bug or feature?
To: None <current-users@NetBSD.ORG>
From: Peter Seebach <email@example.com>
Date: 04/22/1997 00:08:21
I've got a piece of code, many moons old, which does something like
width = tgetnum("co");
This has worked forever.
Suddenly, it is dumping core.
Study reveals that running tgetent() before doing this fixes the
core dump. No other system I currently have access to requires me
to run tgetent first. The documentation (which looks fairly pre-ANSI)
does not seem to hint at a definitive answer.
Bug? Feature? I could go either way on this, although I slightly prefer
the behavior I get elsewhere, where tget* all work on the current terminal
type unless I run tgetent to look at a different one.