circo

claudio's IRC oasis
git clone git://git.bitsmanent.org/circo
Log | Files | Refs | README | LICENSE

commit 6ec80047624d575776df0fac03e18a9deb466bdd
parent 7020fb3180ab5d856629918a9887228ea309b44b
Author: Claudio Alessi <smoppy@gmail.com>
Date:   Fri, 14 Jul 2017 21:05:52 +0200

Use cfmakeraw() to initialize terminal.

Diffstat:
Mcirco.c | 4+++-
1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/circo.c b/circo.c @@ -572,8 +572,10 @@ setup(void) { sa.sa_handler = sigwinch; sigaction(SIGWINCH, &sa, NULL); tcgetattr(0, &origti); - ti.c_lflag &= ~(ECHO | ICANON); + cfmakeraw(&ti); ti.c_iflag |= ICRNL; + ti.c_cc[VMIN] = 0; + ti.c_cc[VTIME] = 0; tcsetattr(0, TCSAFLUSH, &ti); ioctl(0, TIOCGWINSZ, &ws);