Mercurial > emacs
changeset 12491:4ad7be34ece1
(Fstart_process): Expand PROGRAM.
Error if it is a directory.
author | Richard M. Stallman <rms@gnu.org> |
---|---|
date | Fri, 07 Jul 1995 13:34:16 +0000 |
parents | c641ffcd1d1b |
children | 27497b336977 |
files | src/process.c |
diffstat | 1 files changed, 8 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/src/process.c Fri Jul 07 13:33:29 1995 +0000 +++ b/src/process.c Fri Jul 07 13:34:16 1995 +0000 @@ -1080,6 +1080,8 @@ #else /* not VMS */ new_argv = (unsigned char **) alloca ((nargs - 1) * sizeof (char *)); + program = Fexpand_file_name (program, Qnil); + /* If program file name is not absolute, search our path for it */ if (!IS_DIRECTORY_SEP (XSTRING (program)->data[0]) && !(XSTRING (program)->size > 1 @@ -1096,7 +1098,12 @@ new_argv[0] = XSTRING (tem)->data; } else - new_argv[0] = XSTRING (program)->data; + { + if (!NILP (Ffile_directory_p (program))) + error ("Specified program for new process is a directory"); + + new_argv[0] = XSTRING (program)->data; + } for (i = 3; i < nargs; i++) {