This is arrises a new question, since both using read() or using
termio to put the terminal out of cooked mode solve the problem, using
which of this builds up a better coding style, or better said: the
correct coding style.
First, these function make for somewhat unportable code. The code that I
On Sun, 1 Jun 2003 11:03:20 -0400 (PYT)
Raúl Gutiérrez Segalés wrote:
presented should work on most Unix and Linux systems (except maybe SCO),
but on Windows, you might want to use the conio functions. As I created
a separate function to wait for a keypress, it is best to make
non-portable code into separate entities such that you can easily add
that functionality on another platform. (by separate entity, I mean a
separate function or macro).
--
Jerry Feldman
Boston Linux and Unix user group
http://www.blu.org PGP key id:C5061EA9
PGP Key fingerprint:053C 73EC 3AC1 5C44 3E14 9245 FB00 3ED5 C506 1EA9