winsize struct

Jonathan I. Kamens jik at athena.mit.edu
Wed Feb 13 08:14:50 AEST 1991


In article <1991Feb11.192013.6587 at mccc.edu>, pjh at mccc.edu (Pete Holsberg) writes:
|> A couple of the programs I've tried to compile have required the winsize
|> struct, found in <ptem.h>, I believe.  However, with both Microport's
|> K&R compiler and with the AT&T ANSI compiler, there is *no* include file
|> that defines that struct!
|> 
|> If someone could send me the definition, I'd be grateful.

  First of all, on many systems, the winsize structure is defined in
<sys/ioctl.h>, not in <ptem.h>.

  Second, if you're using a system that doesn't define the winsize structure
in any of its header files, the most likely explanation is that the system
doesn't *support* the SIGWINCH signal or the TIOCGWINSZ and TIOCSWINSZ
ioctl's, so defining the structure isn't going to help you.

  The programs should be written in such a way that allows you to disable the
use of the winsize stuff.  If they aren't, they should be modified so that
they are, using preprocessor symbols to determine whether the system on which
they are being compiled has winsize.

-- 
Jonathan Kamens			              USnail:
MIT Project Athena				11 Ashford Terrace
jik at Athena.MIT.EDU				Allston, MA  02134
Office: 617-253-8085			      Home: 617-782-0710



More information about the Comp.unix.programmer mailing list