From: dick.r.chiang@gmail.com
To: 43202@debbugs.gnu.org
Subject: bug#43202: patch
Date: Fri, 04 Sep 2020 09:01:08 -0400 [thread overview]
Message-ID: <87tuwdr90r.fsf@dick> (raw)
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: 0001-Squashed-commit-of-the-following.patch --]
[-- Type: text/x-diff, Size: 1915 bytes --]
From 50446fc44e54a989db0863b5c8c887043e1226f9 Mon Sep 17 00:00:00 2001
From: dickmao <none>
Date: Fri, 4 Sep 2020 08:57:58 -0400
Subject: [PATCH] Squashed commit of the following:
commit 4ceb578a9c9a93ea44f61e7453aae5b8c2ed90e6
Author: dickmao <none>
Date: Fri Sep 4 08:55:39 2020 -0400
avoid `Wrong type argument` in `list-processes--refresh`
Should not expect sequencep from `process-command` for network,
serial, pipe.
* lisp/simple.el (list-processes--refresh): network, serial, *or pipe*.
* test/src/process-tests.el (process-test-stopped-pipe): add a test.
---
lisp/simple.el | 2 +-
test/src/process-tests.el | 9 +++++++++
2 files changed, 10 insertions(+), 1 deletion(-)
diff --git a/lisp/simple.el b/lisp/simple.el
index eedbff2d08..e7eb33b200 100644
--- a/lisp/simple.el
+++ b/lisp/simple.el
@@ -4374,7 +4374,7 @@ list-processes--refresh
((thread-name (process-thread p)))
(t "--")))
(cmd
- (if (memq type '(network serial))
+ (if (memq type '(network serial pipe))
(let ((contact (process-contact p t t)))
(if (eq type 'network)
(format "(%s %s)"
diff --git a/test/src/process-tests.el b/test/src/process-tests.el
index e15ad47f96..c45b00a776 100644
--- a/test/src/process-tests.el
+++ b/test/src/process-tests.el
@@ -105,6 +105,15 @@ process-test-stderr-buffer
(goto-char (point-min))
(looking-at "hello stderr!")))))
+(ert-deftest process-test-stopped-pipe ()
+ (skip-unless (executable-find "cat"))
+ (with-temp-buffer
+ (let ((proc (make-pipe-process :name "pipe" :buffer (current-buffer)
+ :command '("cat") :stop t)))
+ (unwind-protect
+ (should (list-processes--refresh))
+ (delete-process proc)))))
+
(ert-deftest process-test-stderr-filter ()
(skip-unless (executable-find "bash"))
(let* ((sentinel-called nil)
--
2.26.2
next reply other threads:[~2020-09-04 13:01 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-09-04 13:01 dick.r.chiang [this message]
2020-09-04 13:29 ` bug#43202: patch Lars Ingebrigtsen
2020-09-06 21:20 ` Lars Ingebrigtsen
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
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87tuwdr90r.fsf@dick \
--to=dick.r.chiang@gmail.com \
--cc=43202@debbugs.gnu.org \
/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 public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).