From 643b207dc4f8c676926a711154fdfb389b9ae426 Mon Sep 17 00:00:00 2001 From: Chris Hanson Date: Thu, 1 May 1997 03:51:13 +0000 Subject: [PATCH] Changes needed to get PTY subprocesses working under BSDI. --- v7/src/microcode/uxproc.c | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/v7/src/microcode/uxproc.c b/v7/src/microcode/uxproc.c index 8287e92de..eb79497d5 100644 --- a/v7/src/microcode/uxproc.c +++ b/v7/src/microcode/uxproc.c @@ -1,8 +1,8 @@ /* -*-C-*- -$Id: uxproc.c,v 1.19 1996/03/11 20:38:24 cph Exp $ +$Id: uxproc.c,v 1.20 1997/05/01 03:51:13 cph Exp $ -Copyright (c) 1990-96 Massachusetts Institute of Technology +Copyright (c) 1990-97 Massachusetts Institute of Technology This material was developed by the Scheme project at the Massachusetts Institute of Technology, Department of Electrical Engineering and @@ -41,6 +41,10 @@ MIT in each case. */ #include "error: can't hack subprocess I/O without dup2() or equivalent" #endif +#if defined(__osf__) || defined(__bsdi__) +#define USE_TIOCSCTTY +#endif + extern char ** environ; extern void EXFUN ((*subprocess_death_hook), (pid_t pid, wait_status_t * status)); @@ -355,7 +359,7 @@ DEFUN (OS_make_subprocess, || ((SLAVE_PTY_P (ctty_name)) && (! (SETUP_SLAVE_PTY (fd)))) #endif || (! (isatty (fd))) -#ifdef __osf__ +#ifdef USE_TIOCSCTTY || ((UX_ioctl (fd, TIOCSCTTY, 0)) < 0) #endif /* Tell the controlling terminal its process group. */ @@ -701,7 +705,6 @@ DEFUN (stop_signal_handler, (signo), int signo) must disable them if they are present. */ #define IUCLC 0 #define OLCUC 0 -#define ONLCR 0 #define NLDLY 0 #define CRDLY 0 #define TABDLY 0 @@ -710,6 +713,10 @@ DEFUN (stop_signal_handler, (signo), int signo) #define FFDLY 0 #endif +#ifndef ONLCR +#define ONLCR 0 +#endif + static int DEFUN (child_setup_tty, (fd), int fd) { -- 2.25.1