diff options
| author | Charles A. Roelli | 2018-12-22 17:14:36 +0100 |
|---|---|---|
| committer | Charles A. Roelli | 2018-12-22 17:14:36 +0100 |
| commit | 24ddea074a2e61f7accde60cdf941ba67b1ce82a (patch) | |
| tree | 478dd0169c6f2cec90deb772c0ddac0670e94143 | |
| parent | 29310168310e807d289e789a1134df95c366d133 (diff) | |
| download | emacs-24ddea074a2e61f7accde60cdf941ba67b1ce82a.tar.gz emacs-24ddea074a2e61f7accde60cdf941ba67b1ce82a.zip | |
Improve process doc. with respect to handling of large input (Bug#33191)
* src/process.c (Fprocess_send_region, Fprocess_send_string):
Document that process input longer than the process input
buffer may be split into bunches. Remove an outdated
reference to a 500 character split boundary.
* doc/lispref/processes.texi (Asynchronous Processes): Remove
mention of "stray character injections" in PTY processes. See
also the comment about ICANON in src/sysdep.c, function
child_setup_tty.
| -rw-r--r-- | doc/lispref/processes.texi | 7 | ||||
| -rw-r--r-- | src/process.c | 15 |
2 files changed, 12 insertions, 10 deletions
diff --git a/doc/lispref/processes.texi b/doc/lispref/processes.texi index e7d61bd5faa..623be09cc63 100644 --- a/doc/lispref/processes.texi +++ b/doc/lispref/processes.texi | |||
| @@ -604,10 +604,9 @@ these features. However, for subprocesses used by Lisp programs for | |||
| 604 | internal purposes (i.e., no user interaction with the subprocess is | 604 | internal purposes (i.e., no user interaction with the subprocess is |
| 605 | required), where significant amounts of data need to be exchanged | 605 | required), where significant amounts of data need to be exchanged |
| 606 | between the subprocess and the Lisp program, it is often better to use | 606 | between the subprocess and the Lisp program, it is often better to use |
| 607 | a pipe, because pipes are more efficient, and because they are immune | 607 | a pipe, because pipes are more efficient. Also, the total number of |
| 608 | to stray character injections that ptys introduce for large (around | 608 | ptys is limited on many systems, and it is good not to waste them |
| 609 | 500 byte) messages. Also, the total number of ptys is limited on many | 609 | unnecessarily. |
| 610 | systems, and it is good not to waste them unnecessarily. | ||
| 611 | 610 | ||
| 612 | @defun make-process &rest args | 611 | @defun make-process &rest args |
| 613 | This function is the basic low-level primitive for starting | 612 | This function is the basic low-level primitive for starting |
diff --git a/src/process.c b/src/process.c index b0a327229c6..e306b2ae9ec 100644 --- a/src/process.c +++ b/src/process.c | |||
| @@ -6456,9 +6456,11 @@ DEFUN ("process-send-region", Fprocess_send_region, Sprocess_send_region, | |||
| 6456 | PROCESS may be a process, a buffer, the name of a process or buffer, or | 6456 | PROCESS may be a process, a buffer, the name of a process or buffer, or |
| 6457 | nil, indicating the current buffer's process. | 6457 | nil, indicating the current buffer's process. |
| 6458 | Called from program, takes three arguments, PROCESS, START and END. | 6458 | Called from program, takes three arguments, PROCESS, START and END. |
| 6459 | If the region is more than 500 characters long, | 6459 | If the region is larger than the input buffer of the process (the |
| 6460 | it is sent in several bunches. This may happen even for shorter regions. | 6460 | length of which depends on the process connection type and the |
| 6461 | Output from processes can arrive in between bunches. | 6461 | operating system), it is sent in several bunches. This may happen |
| 6462 | even for shorter regions. Output from processes can arrive in between | ||
| 6463 | bunches. | ||
| 6462 | 6464 | ||
| 6463 | If PROCESS is a non-blocking network process that hasn't been fully | 6465 | If PROCESS is a non-blocking network process that hasn't been fully |
| 6464 | set up yet, this function will block until socket setup has completed. */) | 6466 | set up yet, this function will block until socket setup has completed. */) |
| @@ -6489,9 +6491,10 @@ DEFUN ("process-send-string", Fprocess_send_string, Sprocess_send_string, | |||
| 6489 | doc: /* Send PROCESS the contents of STRING as input. | 6491 | doc: /* Send PROCESS the contents of STRING as input. |
| 6490 | PROCESS may be a process, a buffer, the name of a process or buffer, or | 6492 | PROCESS may be a process, a buffer, the name of a process or buffer, or |
| 6491 | nil, indicating the current buffer's process. | 6493 | nil, indicating the current buffer's process. |
| 6492 | If STRING is more than 500 characters long, | 6494 | If STRING is larger than the input buffer of the process (the length |
| 6493 | it is sent in several bunches. This may happen even for shorter strings. | 6495 | of which depends on the process connection type and the operating |
| 6494 | Output from processes can arrive in between bunches. | 6496 | system), it is sent in several bunches. This may happen even for |
| 6497 | shorter strings. Output from processes can arrive in between bunches. | ||
| 6495 | 6498 | ||
| 6496 | If PROCESS is a non-blocking network process that hasn't been fully | 6499 | If PROCESS is a non-blocking network process that hasn't been fully |
| 6497 | set up yet, this function will block until socket setup has completed. */) | 6500 | set up yet, this function will block until socket setup has completed. */) |