From owner-freebsd-bugs Wed Mar 11 08:50:05 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id IAA07068 for freebsd-bugs-outgoing; Wed, 11 Mar 1998 08:50:05 -0800 (PST) (envelope-from owner-freebsd-bugs@FreeBSD.ORG) Received: (from gnats@localhost) by hub.freebsd.org (8.8.8/8.8.8) id IAA07049; Wed, 11 Mar 1998 08:50:02 -0800 (PST) (envelope-from gnats) Date: Wed, 11 Mar 1998 08:50:02 -0800 (PST) Message-Id: <199803111650.IAA07049@hub.freebsd.org> To: freebsd-bugs Cc: From: Nick Subject: Re: bin/5959: Cannot set up clocal gettys Reply-To: Nick Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org The following reply was made to PR bin/5959; it has been noted by GNATS. From: Nick To: freebsd-gnats-submit@freebsd.org Cc: Subject: Re: bin/5959: Cannot set up clocal gettys Date: Wed, 11 Mar 1998 16:42:41 +0000 This patch adds the 'nc' flag to getty, which will make getty open non-blocking and set clocal. Many wet noodle whippings to getty for totally and willfully destroying the settings one sets up on the i device. --- init.c.orig Sat May 10 22:28:54 1997 +++ init.c Tue Mar 10 16:45:48 1998 @@ -142,5 +142,6 @@ { "np", 0 }, /* no parity at all (8bit chars) */ { "mb", 0 }, /* do MDMBUF flow control */ { "hw", 0 }, /* do CTSRTS flow control */ + { "nc", 0 }, /* set clocal */ { 0 } }; --- gettytab.h.orig Sat May 10 22:28:53 1997 +++ gettytab.h Tue Mar 10 16:52:04 1998 @@ -170,4 +170,5 @@ #define NP gettyflags[21].value #define MB gettyflags[22].value #define HW gettyflags[23].value +#define NC gettyflags[24].value --- main.c.orig Sun Aug 17 16:44:34 1997 +++ main.c Tue Mar 10 16:57:58 1998 @@ -266,8 +266,8 @@ (void)tcsetattr(STDIN_FILENO, TCSANOW, &tmode); exit(1); } - } else { /* blocking open */ - if (!opentty(ttyn, O_RDWR)) + } else { /* maybe blocking open */ + if (!opentty(ttyn, O_RDWR|(NC?O_NONBLOCK:0))) exit(1); } } @@ -289,6 +289,7 @@ tmode.c_oflag = TTYDEF_OFLAG; tmode.c_lflag = TTYDEF_LFLAG; tmode.c_cflag = TTYDEF_CFLAG; + tmode.c_cflag |= (NC?CLOCAL:0); omode = tmode; To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message