]> git.eshelyaron.com Git - emacs.git/commit
Make piping to subprocesses more robust on MS-Windows
authorEli Zaretskii <eliz@gnu.org>
Tue, 12 Jan 2016 16:41:58 +0000 (18:41 +0200)
committerEli Zaretskii <eliz@gnu.org>
Tue, 12 Jan 2016 16:41:58 +0000 (18:41 +0200)
commit58a622d473112f8ff5b4bdb3e49bc6573dfd3404
tree58b618f654cae22d1e5f102cbb48bec56e833d45
parent1f6898d0510cd15455f665c0f38451755a374243
Make piping to subprocesses more robust on MS-Windows

* src/w32.c (sys_write): Don't write to a pipe more stuff than its
buffer can hold.  Don't return -1 if something has been written to
the pipe.  Zero out 'errno' before calling '_write', to avoid
returning a stale value.  (Bug#22344)
* src/w32proc.c (syms_of_ntproc) <w32-pipe-buffer-size>: New variable.
* src/w32.c (pipe2): Use it to request a user-defined size for the
pipe being created.

* etc/NEWS: Mention 'w32-pipe-buffer-size'.

* doc/emacs/msdos.texi (Windows Processes): Document
'w32-pipe-buffer-size'.
doc/emacs/msdos.texi
etc/NEWS
src/w32.c
src/w32proc.c