summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorPhilipp Stephani <phst@google.com>2019-04-19 13:03:40 +0200
committerPhilipp Stephani <phst@google.com>2019-04-19 14:03:16 +0200
commit5c5e309527e6b582e2c04b83e7af45f3144863ac (patch)
tree0a19797e7e67663915d95b72ea5452c80b5dc552 /src
parent3ff7d7321ac62b1eb896e8a032e7f75f5a6b8146 (diff)
downloademacs-5c5e309527e6b582e2c04b83e7af45f3144863ac.tar.gz
Remove :stop key from make-process.
This has never worked and caused issues such as Bug#30460. * src/process.c (Fmake_process): Don't accept :stop key any more. (syms_of_process): Define needed symbol 'null'. * test/src/process-tests.el (make-process/stop): New unit test. * doc/lispref/processes.texi (Asynchronous Processes): Remove :stop key from manual.
Diffstat (limited to 'src')
-rw-r--r--src/process.c17
1 files changed, 11 insertions, 6 deletions
diff --git a/src/process.c b/src/process.c
index 0c440371628..6717ccb4187 100644
--- a/src/process.c
+++ b/src/process.c
@@ -1643,10 +1643,11 @@ ENCODING is used for writing.
:noquery BOOL -- When exiting Emacs, query the user if BOOL is nil and
the process is running. If BOOL is not given, query before exiting.
-:stop BOOL -- Start process in the `stopped' state if BOOL non-nil.
-In the stopped state, a process does not accept incoming data, but you
-can send outgoing data. The stopped state is cleared by
-`continue-process' and set by `stop-process'.
+:stop BOOL -- BOOL must be nil. The `:stop' key is ignored otherwise
+and is retained for compatibility with other process types such as
+pipe processes. Asynchronous subprocesses never start in the
+`stopped' state. Use `stop-process' and `continue-process' to send
+signals to stop and continue a process.
:connection-type TYPE -- TYPE is control type of device used to
communicate with subprocesses. Values are `pipe' to use a pipe, `pty'
@@ -1746,8 +1747,10 @@ usage: (make-process &rest ARGS) */)
if (!query_on_exit)
XPROCESS (proc)->kill_without_query = 1;
- if (tem = Fplist_get (contact, QCstop), !NILP (tem))
- pset_command (XPROCESS (proc), Qt);
+ tem = Fplist_get (contact, QCstop);
+ /* Normal processes can't be started in a stopped state, see
+ Bug#30460. */
+ CHECK_TYPE (NILP (tem), Qnull, tem);
tem = Fplist_get (contact, QCconnection_type);
if (EQ (tem, Qpty))
@@ -8300,6 +8303,8 @@ returns non-`nil'. */);
"internal-default-interrupt-process");
DEFSYM (Qinterrupt_process_functions, "interrupt-process-functions");
+ DEFSYM (Qnull, "null");
+
defsubr (&Sprocessp);
defsubr (&Sget_process);
defsubr (&Sdelete_process);