comparison src/process.c @ 5347:21bffe027a7d

(create_process) [NTTYDISC]: Set the tty line discipline.
author Richard M. Stallman <rms@gnu.org>
date Sat, 25 Dec 1993 01:44:47 +0000
parents c559b3d1b9e4
children a609e717764d
comparison
equal deleted inserted replaced
5346:65beb670c6b1 5347:21bffe027a7d
1234 because faith@cs.unc.edu says that is necessary on Linux. */ 1234 because faith@cs.unc.edu says that is necessary on Linux. */
1235 ioctl (xforkin, TIOCSCTTY, 0); 1235 ioctl (xforkin, TIOCSCTTY, 0);
1236 #endif 1236 #endif
1237 #else /* not HAVE_SETSID */ 1237 #else /* not HAVE_SETSID */
1238 #ifdef USG 1238 #ifdef USG
1239 /* It's very important to call setpgrp() here and no time 1239 /* It's very important to call setpgrp here and no time
1240 afterwards. Otherwise, we lose our controlling tty which 1240 afterwards. Otherwise, we lose our controlling tty which
1241 is set when we open the pty. */ 1241 is set when we open the pty. */
1242 setpgrp (); 1242 setpgrp ();
1243 #endif /* USG */ 1243 #endif /* USG */
1244 #endif /* not HAVE_SETSID */ 1244 #endif /* not HAVE_SETSID */
1245 #ifdef NTTYDISC
1246 {
1247 /* Use new line discipline. */
1248 int ldisc = NTTYDISC;
1249 if (ioctl (xforkin, TIOCSETD, &ldisc) < 0)
1250 write (1, "create_process/TIOCSETD failed\n", 31);
1251 }
1252 #endif
1245 #ifdef TIOCNOTTY 1253 #ifdef TIOCNOTTY
1246 /* In 4.3BSD, the TIOCSPGRP bug has been fixed, and now you 1254 /* In 4.3BSD, the TIOCSPGRP bug has been fixed, and now you
1247 can do TIOCSPGRP only to the process's controlling tty. */ 1255 can do TIOCSPGRP only to the process's controlling tty. */
1248 if (pty_flag) 1256 if (pty_flag)
1249 { 1257 {