From ef5c6a6edaf3dcf2cddd46841dc0dd8fce2bf967 Mon Sep 17 00:00:00 2001 From: Russ Cox Date: Fri, 3 Sep 2010 10:21:16 -0400 Subject: 9term, win: better echo cancellation Also just drop \r from output. It's a losing battle to keep turning it off. R=rsc http://codereview.appspot.com/2128042 --- src/cmd/9term/SunOS.c | 19 ------------------- 1 file changed, 19 deletions(-) (limited to 'src/cmd/9term/SunOS.c') diff --git a/src/cmd/9term/SunOS.c b/src/cmd/9term/SunOS.c index ac1432de..e0f866ab 100644 --- a/src/cmd/9term/SunOS.c +++ b/src/cmd/9term/SunOS.c @@ -77,25 +77,6 @@ isecho(int fd) return (ttmode.c_lflag&ICANON && ttmode.c_lflag&ECHO); } -int -setecho(int fd, int newe) -{ - int old; - - if(tcgetattr(fd, &ttmode) < 0) - fprint(2, "tcgetattr: %r\n"); - old = (ttmode.c_lflag&ECHO)==ECHO; - if(old != newe){ - if(newe) - ttmode.c_lflag |= ECHO; - else - ttmode.c_lflag &= ~ECHO; - if(tcsetattr(fd, TCSANOW, &ttmode) < 0) - fprint(2, "tcsetattr: %r\n"); - } - return old; -} - int getintr(int fd) { -- cgit v1.2.3