diff options
author | Karl Heuer <kwzh@gnu.org> | 1995-04-28 01:43:02 +0000 |
---|---|---|
committer | Karl Heuer <kwzh@gnu.org> | 1995-04-28 01:43:02 +0000 |
commit | 4779c242f1f8a5e0a6a556dfcd9f67fafef24ada (patch) | |
tree | d9657d48683f6dfcc0402b1783d2b91d8ec091c3 /src/process.c | |
parent | 31fe33d127f314f95974bb043fcb0eca8ce46fbb (diff) | |
download | emacs-4779c242f1f8a5e0a6a556dfcd9f67fafef24ada.tar.gz |
(create_process): Don't reference pty_name if !HAVE_PTYS.
Diffstat (limited to 'src/process.c')
-rw-r--r-- | src/process.c | 19 |
1 files changed, 14 insertions, 5 deletions
diff --git a/src/process.c b/src/process.c index 83de691d393..14fa3144339 100644 --- a/src/process.c +++ b/src/process.c @@ -248,12 +248,11 @@ static Lisp_Object get_process (); /* Maximum number of bytes to send to a pty without an eof. */ static int pty_max_bytes; -/* Open an available pty, returning a file descriptor. - Return -1 on failure. - The file name of the terminal corresponding to the pty - is left in the variable pty_name. */ +#ifdef HAVE_PTYS +/* The file name of the pty opened by allocate_pty. */ static char pty_name[24]; +#endif /* Compute the Lisp form of the process status, p->status, from the numeric status that was returned by `wait'. */ @@ -363,6 +362,11 @@ status_message (status) #ifdef HAVE_PTYS +/* Open an available pty, returning a file descriptor. + Return -1 on failure. + The file name of the terminal corresponding to the pty + is left in the variable pty_name. */ + int allocate_pty () { @@ -1499,7 +1503,12 @@ create_process (process, new_argv, current_dir) if (forkin != forkout && forkout >= 0) close (forkout); - XPROCESS (process)->tty_name = pty_flag ? build_string (pty_name) : Qnil; +#ifdef HAVE_PTYS + if (pty_flag) + XPROCESS (process)->tty_name = build_string (pty_name); + else +#endif + XPROCESS (process)->tty_name = Qnil; #ifdef SIGCHLD #ifdef BSD4_1 |