Ignore 'eshell-broken-pipe' error in 'eshell-sentinel'

This can happen if 'eshell-sentinel' tries to write output to another
process, but that process has already terminated.

* lisp/eshell/esh-proc.el (eshell-sentinel): Use 'ignore-error'
instead of 'unwind-protect'.
This commit is contained in:
Jim Porter 2022-02-21 12:14:34 -08:00 committed by Lars Ingebrigtsen
parent 7b0b27971b
commit 76fcfe1eb1

View file

@ -435,12 +435,12 @@ PROC is the process that's exiting. STRING is the exit message."
(lambda ()
(if (nth 4 entry)
(run-at-time 0 nil finish-io)
(unwind-protect
(when str
(eshell-output-object
str nil handles))
(eshell-close-handles
status 'nil handles))))))
(when str
(ignore-error 'eshell-pipe-broken
(eshell-output-object
str nil handles)))
(eshell-close-handles
status 'nil handles)))))
(funcall finish-io)))))
(eshell-remove-process-entry entry))))
(eshell-kill-process-function proc string)))))