From: hackbard Date: Sun, 7 Nov 2004 11:51:09 +0000 (+0000) Subject: care for echo and nanonc mode on beofre switching off X-Git-Url: https://hackdaworld.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=7dca7a2ba9fa3597d3bbc349b9f56c164d63b2d9;p=my-code%2Fapi.git care for echo and nanonc mode on beofre switching off --- diff --git a/input/input.c b/input/input.c index 0060f52..285a08d 100644 --- a/input/input.c +++ b/input/input.c @@ -40,6 +40,8 @@ int input_ios_init(t_input *input) { tios.c_cc[VMIN]=1; /* 1 char for non-can. mode */ /* depending on used modes */ + tios.c_lflag|=ICANON; + tios.c_lflag|=ECHO; if(!(input->mode&LINE_BUFFERED)) tios.c_lflag&=(~ICANON); if(!(input->mode&INPUT_ECHO)) tios.c_lflag&=(~ECHO);