From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Lars Ingebrigtsen Newsgroups: gmane.emacs.bugs Subject: bug#38035: 27.0.50; Trivial errors in process filters can render Emacs unusable Date: Sat, 02 Nov 2019 18:53:57 +0100 Message-ID: <874kzmdv0q.fsf@gnus.org> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="139594"; mail-complaints-to="usenet@blaine.gmane.org" To: 38035@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sat Nov 02 18:55:14 2019 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([209.51.188.17]) by blaine.gmane.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1iQxcF-000a7P-N9 for geb-bug-gnu-emacs@m.gmane.org; Sat, 02 Nov 2019 18:55:11 +0100 Original-Received: from localhost ([::1]:49604 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1iQxcD-0003dd-PH for geb-bug-gnu-emacs@m.gmane.org; Sat, 02 Nov 2019 13:55:09 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:50324) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1iQxc7-0003dP-B2 for bug-gnu-emacs@gnu.org; Sat, 02 Nov 2019 13:55:04 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1iQxc6-0001Nv-63 for bug-gnu-emacs@gnu.org; Sat, 02 Nov 2019 13:55:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:52473) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1iQxc6-0001Mw-02 for bug-gnu-emacs@gnu.org; Sat, 02 Nov 2019 13:55:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1iQxc5-0002Tp-S9 for bug-gnu-emacs@gnu.org; Sat, 02 Nov 2019 13:55:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Lars Ingebrigtsen Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 02 Nov 2019 17:55:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 38035 X-GNU-PR-Package: emacs X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Original-Received: via spool by submit@debbugs.gnu.org id=B.15727172479444 (code B ref -1); Sat, 02 Nov 2019 17:55:01 +0000 Original-Received: (at submit) by debbugs.gnu.org; 2 Nov 2019 17:54:07 +0000 Original-Received: from localhost ([127.0.0.1]:33058 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iQxbD-0002SG-B4 for submit@debbugs.gnu.org; Sat, 02 Nov 2019 13:54:07 -0400 Original-Received: from lists.gnu.org ([209.51.188.17]:48994) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iQxbB-0002S6-BC for submit@debbugs.gnu.org; Sat, 02 Nov 2019 13:54:06 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:50104) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1iQxb9-0003aH-W0 for bug-gnu-emacs@gnu.org; Sat, 02 Nov 2019 13:54:05 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1iQxb8-0004tM-PR for bug-gnu-emacs@gnu.org; Sat, 02 Nov 2019 13:54:03 -0400 Original-Received: from quimby.gnus.org ([80.91.231.51]:52760) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1iQxb8-0004rf-Ic for bug-gnu-emacs@gnu.org; Sat, 02 Nov 2019 13:54:02 -0400 Original-Received: from cm-84.212.202.86.getinternet.no ([84.212.202.86] helo=marnie) by quimby.gnus.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1iQxb4-000512-3x for bug-gnu-emacs@gnu.org; Sat, 02 Nov 2019 18:54:00 +0100 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.51.188.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:170833 Archived-At: If you eval the following, your Emacs will become unusable and you'll have to kill it (so don't eval it): (let ((process (start-process "foo" (get-buffer-create "*foo*") "bash" "-c" "while true; do echo foo; sleep 1; done"))) (set-process-filter process (lambda (&rest _) (error)))) The reason for this is that when signalling an error from a process filter, Emacs messages the error message and then seems to sleep for a second? I haven't investigated the code yet. This is something that has bit me more than a few times when working with process filters (i.e., making a syntax error and then having Emacs blow up on me). I'm not sure what solution would be best. I see two obvious things we could do: Remove the process filter, so that it doesn't trigger again. Or -- remove the one-second sleep, which would allow the user to `M-x list-processes' and kill the offending process. In GNU Emacs 27.0.50 (build 6, x86_64-pc-linux-gnu, GTK+ Version 3.24.5) of 2019-11-01 built on marnie Repository revision: eda98211e31ed969823c1048b3cde635e08eebe5 Repository branch: master Windowing system distributor 'The X.Org Foundation', version 11.0.12004000 System Description: Debian GNU/Linux 10 (buster) -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no