From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#42160: Issue with Man-kill and background process. Date: Sat, 18 Jul 2020 10:46:07 +0300 Message-ID: <83blkdi7uo.fsf@gnu.org> References: <20200702022309.bpj4t77e73n23c4y.ref@ergus> <20200702022309.bpj4t77e73n23c4y@ergus> <835zb5vxfj.fsf@gnu.org> <83imevq2hd.fsf@gnu.org> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="40600"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 42160@debbugs.gnu.org To: spacibba@aol.com Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sat Jul 18 09:47:09 2020 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jwhYq-000AQr-Kt for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 18 Jul 2020 09:47:08 +0200 Original-Received: from localhost ([::1]:48774 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jwhYp-0007rJ-Nj for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 18 Jul 2020 03:47:07 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:58992) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jwhYj-0007rC-WA for bug-gnu-emacs@gnu.org; Sat, 18 Jul 2020 03:47:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:46841) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jwhYj-0000Tm-N7 for bug-gnu-emacs@gnu.org; Sat, 18 Jul 2020 03:47:01 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1jwhYj-0004if-Lj for bug-gnu-emacs@gnu.org; Sat, 18 Jul 2020 03:47:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 18 Jul 2020 07:47:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 42160 X-GNU-PR-Package: emacs Original-Received: via spool by 42160-submit@debbugs.gnu.org id=B42160.159505838618098 (code B ref 42160); Sat, 18 Jul 2020 07:47:01 +0000 Original-Received: (at 42160) by debbugs.gnu.org; 18 Jul 2020 07:46:26 +0000 Original-Received: from localhost ([127.0.0.1]:58387 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jwhY9-0004hp-Mj for submit@debbugs.gnu.org; Sat, 18 Jul 2020 03:46:25 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:45152) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jwhY8-0004hd-Jx for 42160@debbugs.gnu.org; Sat, 18 Jul 2020 03:46:25 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:47119) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jwhY3-0000LO-9e; Sat, 18 Jul 2020 03:46:19 -0400 Original-Received: from [176.228.60.248] (port=3863 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1jwhY2-0000ph-JL; Sat, 18 Jul 2020 03:46:19 -0400 In-Reply-To: <83imevq2hd.fsf@gnu.org> (message from Eli Zaretskii on Fri, 10 Jul 2020 09:59:58 +0300) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list 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-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:183164 Archived-At: Ping! Ping! Jimmy, could you please try this patch and see if it fixes your problems? If it does, I' d like to install it. > Date: Fri, 10 Jul 2020 09:59:58 +0300 > From: Eli Zaretskii > Cc: 42160@debbugs.gnu.org > > Ping! > > > Date: Fri, 03 Jul 2020 11:02:08 +0300 > > From: Eli Zaretskii > > Cc: 42160@debbugs.gnu.org > > > > > Date: Thu, 2 Jul 2020 04:23:09 +0200 > > > From: Ergus via "Bug reports for GNU Emacs, > > > the Swiss army knife of text editors" > > > > > > When using man with big manuals (like gcc). There is an error when > > > trying to quit with k just after opening the manual. > > > This seems to be related with the formating process that is running in > > > the background. > > > > > > To reproduce the issue: > > > > > > emacs -Q > > > M-x toggle-debug-on-error RET > > > M-x man RET > > > gcc RET > > > k > > > > > > And I get this error message: > > > > > > Debugger entered--Lisp error: (wrong-type-argument stringp nil) > > > Man-bgproc-filter(# "nt, there is no need to use address spaces like \"_...") > > > > Thanks. Does the patch below fix this? > > > > diff --git a/lisp/man.el b/lisp/man.el > > index 5278a1a..bc8fd45 100644 > > --- a/lisp/man.el > > +++ b/lisp/man.el > > @@ -1392,7 +1392,7 @@ Man-bgproc-filter > > command is run. Second argument STRING is the entire string of output." > > (save-excursion > > (let ((Man-buffer (process-buffer process))) > > - (if (null (buffer-name Man-buffer)) ;; deleted buffer > > + (if (not (buffer-live-p Man-buffer)) ;; deleted buffer > > (set-process-buffer process nil) > > > > (with-current-buffer Man-buffer > > @@ -1426,7 +1426,7 @@ Man-bgproc-sentinel > > (delete-buff nil) > > message) > > > > - (if (null (buffer-name Man-buffer)) ;; deleted buffer > > + (if (not (buffer-live-p Man-buffer)) ;; deleted buffer > > (or (stringp process) > > (set-process-buffer process nil)) > > > > > > > > > > > > > >