On 2023-02-12 02:21, Arsen Arsenović wrote: > ... or such. This approach is robust and general, and I suspect it'd > even work for named pipes. Although indeed robust and general and it will work with named pipes in some cases, it still has a problem if the other side of the named pipe outputs data very slowly: Emacs will still seem to hang until you type C-g. That being said, the approach is an improvement and it fixes the original bug report so I installed the attached and am boldly closing the bug report (we can reopen it if I'm wrong). The last patch in the attached series is the actual fix: the others are minor cleanups of this messy area, which I discovered while looking into the fix. This patch does not address the abovementioned issue of named pipes, nor the issue of inserting very large files: the code should behave roughly the same as before in those two areas. These issues can be raised in separate bug reports if needed. PS. I was surprised to see that Emacs master currently has several test case failures on GNU/Linux (specifically the latest Fedora and Ubuntu releases). I hope these are known and that people are working on them. 1 files did not finish: lisp/server-tests.log 4 files contained unexpected results: src/lread-tests.log lisp/international/mule-tests.log lisp/emacs-lisp/map-tests.log lisp/emacs-lisp/bytecomp-tests.log