[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
master ef17ba8370: ; Fix a race condition in an Eshell test
From: |
Jim Porter |
Subject: |
master ef17ba8370: ; Fix a race condition in an Eshell test |
Date: |
Thu, 8 Sep 2022 18:14:36 -0400 (EDT) |
branch: master
commit ef17ba83709794fe0342743397f0e68b90ea1f69
Author: Jim Porter <jporterbugs@gmail.com>
Commit: Jim Porter <jporterbugs@gmail.com>
; Fix a race condition in an Eshell test
* test/lisp/eshell/esh-proc-tests.el
(esh-proc-test/sigpipe-exits-process): Use "|&" when creating the
pipeline to prevent an extra pipe process from being started.
---
test/lisp/eshell/esh-proc-tests.el | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/test/lisp/eshell/esh-proc-tests.el
b/test/lisp/eshell/esh-proc-tests.el
index 52a0d1eeeb..abe363bee0 100644
--- a/test/lisp/eshell/esh-proc-tests.el
+++ b/test/lisp/eshell/esh-proc-tests.el
@@ -128,8 +128,10 @@
(eshell-match-command-output
;; The first command is like `yes' but slower. This is to prevent
;; it from taxing Emacs's process filter too much and causing a
- ;; hang.
- (concat "sh -c 'while true; do echo y; sleep 1; done' | "
+ ;; hang. Note that we use "|&" to connect the processes so that
+ ;; Emacs doesn't create an extra pipe process for the first "sh"
+ ;; invocation.
+ (concat "sh -c 'while true; do echo y; sleep 1; done' |& "
"sh -c 'read NAME; echo ${NAME}'")
"y\n")
(eshell-wait-for-subprocess t)
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- master ef17ba8370: ; Fix a race condition in an Eshell test,
Jim Porter <=