From: Jim Porter <jporterbugs@gmail.com>
To: Stefan Kangas <stefankangas@gmail.com>, 59103@debbugs.gnu.org
Subject: bug#59103: 29.0.50; esh-var-tests intermittently fails on macOS 12.6.1
Date: Fri, 9 Dec 2022 23:14:18 -0800 [thread overview]
Message-ID: <584692ff-1c0c-fdb4-22c3-e515ccc897cb@gmail.com> (raw)
In-Reply-To: <4f0dad10-9664-ce87-6525-0389363b883f@gmail.com>
[-- Attachment #1: Type: text/plain, Size: 460 bytes --]
On 11/7/2022 9:39 PM, Jim Porter wrote:
> On 11/7/2022 3:09 AM, Stefan Kangas wrote:
>> Intermittently failing test on macOS 12.6.1, see below output from
>> "make -j5 check":
>>
> [snip]
>> They do not fail every time: sometimes neither fails, sometimes one
>> does and sometimes the other. Only once did both fail at the same
>> time, after several runs of "make check".
I'm not sure how reliably you can reproduce this, but does the attached
patch help?
[-- Attachment #2: 0001-Fix-a-race-condition-in-Eshell-s-external-process-ma.patch --]
[-- Type: text/plain, Size: 1528 bytes --]
From 94fe9f56748ac8a73b313df80c666dd020a5d46c Mon Sep 17 00:00:00 2001
From: Jim Porter <jporterbugs@gmail.com>
Date: Fri, 9 Dec 2022 23:07:19 -0800
Subject: [PATCH] Fix a race condition in Eshell's external process management
If a process is busy writing output when 'eshell-sentinel' is called,
it might take a bit of time to finish up. Don't call
'eshell-kill-process-function' until we're really finished
(bug#59103).
* lisp/eshell/esh-proc.el (eshell-sentinel): Call
'eshell-kill-process-function' in 'finish-io'.
---
lisp/eshell/esh-proc.el | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/lisp/eshell/esh-proc.el b/lisp/eshell/esh-proc.el
index 950922ea7f8..199ed3cc622 100644
--- a/lisp/eshell/esh-proc.el
+++ b/lisp/eshell/esh-proc.el
@@ -473,11 +473,11 @@ eshell-sentinel
(eshell-close-handles
status
(when status (list 'quote (= status 0)))
- handles)))))
+ handles)
+ (eshell-kill-process-function proc string)))))
(funcall finish-io))))
(when-let ((entry (assq proc eshell-process-list)))
- (eshell-remove-process-entry entry))
- (eshell-kill-process-function proc string)))))
+ (eshell-remove-process-entry entry))))))
(defun eshell-process-interact (func &optional all query)
"Interact with a process, using PROMPT if more than one, via FUNC.
--
2.25.1
next prev parent reply other threads:[~2022-12-10 7:14 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-11-07 11:09 bug#59103: 29.0.50; esh-var-tests intermittently fails on macOS 12.6.1 Stefan Kangas
2022-11-08 5:39 ` Jim Porter
2022-12-10 7:14 ` Jim Porter [this message]
2023-08-27 19:34 ` Jim Porter
2023-08-27 19:51 ` Stefan Kangas
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=584692ff-1c0c-fdb4-22c3-e515ccc897cb@gmail.com \
--to=jporterbugs@gmail.com \
--cc=59103@debbugs.gnu.org \
--cc=stefankangas@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.