Commit Graph

4 Commits

Author SHA1 Message Date
Rong-En Fan
8473fea281 - Sort the headers per style(9)
Reminded by:	yar
Approved by:	delphij (mentor, implicit)
2007-06-06 11:14:30 +00:00
Rong-En Fan
781d8f4e76 - Fix crash with ncurses on FreeBSD/amd64 CURRENT by including missing
header <term.h>, which is required by both tputs() and tgoto().

  Without this header, nvi crashes with the call to tputs() at line 114.
  This is because the first argument of tputs() is a pointer, and the
  returned pointer from tgoto() is casted to an integer by compiler.

  For some reasons, this only crashes on amd64+CURRENT. On 6.x system,
  this does not happen.

PR:		101248
Reported by:	yar, infofarmer, Roland Smith
Tested by:	infofarmer, delphij, rafan
Approved by:	delphij (mentor)
2007-06-06 02:23:03 +00:00
Robert Watson
09333c6166 o nvi failed to correctly handle EINTR returned from tcsetattr(), exiting
instead of recovering, which happens in particular during a rapid series
  of SIGWINCH's.  This change forces nvi to loop on the call in the event
  that the call is interrupted.

Interestingly, I submitted this bug report in 1998, and a solution was
posted shortly thereafter by Matthias Buelow; it's been sitting in the
PR database ever since.

Note: this takes this file off the vendor branch.  If and when we find
a vendor for this code, the fix should be given back to them.

PR:		bin/8438
Submitted by:	Matthias Buelow <mkb@altair.mayn.de>
MFC after:	1 month
2001-11-09 02:23:05 +00:00
Peter Wemm
b8ba871bd9 Import of nvi-1.79, minus a few bits that we dont need (eg: postscript
files, curses, db, regex etc that we already have).  The other glue will
follow shortly.

Obtained from: Keith Bostic <bostic@bostic.com>
1996-11-01 06:45:43 +00:00