From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#30182: Update Date: Thu, 01 Feb 2018 19:44:53 +0200 Message-ID: <83lggceh9m.fsf@gnu.org> References: <87k1wdqc4q.fsf@gmail.com> <5A634E53.7010205@gmx.at> <87mv182bzk.fsf@gmail.com> <83a7x7sww6.fsf@gnu.org> <87efmj27d5.fsf@gmail.com> <83vafvqjbf.fsf@gnu.org> <87inbvxdz8.fsf@gmail.com> <5A65AB97.1030401@gmx.at> <87po62kk10.fsf@gmail.com> <831sih23rh.fsf@gnu.org> <5A663490.3050409@gmx.at> <87r2qh5lya.fsf@gmail.com> <5A6C37A7.2020309@gmx.at> <87r2qag5wp.fsf@gmail.com> <5A6D8947.5010207@gmx.at> <87d11t9ria.fsf@gmail.com> <5A6EF1A2.30904@gmx.at> <83lgggirzp.fsf@gnu.org> <5A702D36.6040302@gmx.at> <83po5rh3pu.fsf@gnu.org> <5A718CFA.2080408@gmx.at> <878tcdtpbk.fsf@gmail.com> <5A72DD44.3060104@gmx.at> Reply-To: Eli Zaretskii NNTP-Posting-Host: blaine.gmane.org X-Trace: blaine.gmane.org 1517507017 13971 195.159.176.226 (1 Feb 2018 17:43:37 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Thu, 1 Feb 2018 17:43:37 +0000 (UTC) Cc: m.sujith@gmail.com, 30182@debbugs.gnu.org To: martin rudalics Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Thu Feb 01 18:43:32 2018 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ehItO-0002hE-Fo for geb-bug-gnu-emacs@m.gmane.org; Thu, 01 Feb 2018 18:43:22 +0100 Original-Received: from localhost ([::1]:50696 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ehIvP-0006Vt-E8 for geb-bug-gnu-emacs@m.gmane.org; Thu, 01 Feb 2018 12:45:27 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:44141) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ehIv3-0006Gk-VI for bug-gnu-emacs@gnu.org; Thu, 01 Feb 2018 12:45:07 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ehIv0-00084w-1W for bug-gnu-emacs@gnu.org; Thu, 01 Feb 2018 12:45:05 -0500 Original-Received: from debbugs.gnu.org ([208.118.235.43]:44760) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1ehIuz-00084m-Tk for bug-gnu-emacs@gnu.org; Thu, 01 Feb 2018 12:45:01 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1ehIuz-000273-N2 for bug-gnu-emacs@gnu.org; Thu, 01 Feb 2018 12:45:01 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 01 Feb 2018 17:45:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 30182 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 30182-submit@debbugs.gnu.org id=B30182.15175070888078 (code B ref 30182); Thu, 01 Feb 2018 17:45:01 +0000 Original-Received: (at 30182) by debbugs.gnu.org; 1 Feb 2018 17:44:48 +0000 Original-Received: from localhost ([127.0.0.1]:52657 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ehIum-00026E-2g for submit@debbugs.gnu.org; Thu, 01 Feb 2018 12:44:48 -0500 Original-Received: from eggs.gnu.org ([208.118.235.92]:53060) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ehIuk-00025z-ON for 30182@debbugs.gnu.org; Thu, 01 Feb 2018 12:44:47 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ehIub-0007iK-Gq for 30182@debbugs.gnu.org; Thu, 01 Feb 2018 12:44:41 -0500 Original-Received: from fencepost.gnu.org ([2001:4830:134:3::e]:50632) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ehIub-0007iC-DK; Thu, 01 Feb 2018 12:44:37 -0500 Original-Received: from [176.228.60.248] (port=1784 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1ehIua-00012K-RP; Thu, 01 Feb 2018 12:44:37 -0500 In-reply-to: <5A72DD44.3060104@gmx.at> (message from martin rudalics on Thu, 01 Feb 2018 10:26:28 +0100) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] 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: 208.118.235.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:142771 Archived-At: > Date: Thu, 01 Feb 2018 10:26:28 +0100 > From: martin rudalics > CC: Eli Zaretskii , 30182@debbugs.gnu.org > > > With the patch applied on top of master, this message is printed in > > *Messages* when the mouse cursor is moved over the modeline. It happens > > only once. > > Thank you very much. > > > Error during redisplay: (eval (w3m-modeline-title)) signaled (error "Attempt to add [t 23154 31461 636625 nil #[(buffer) \\302!\\205\0rq\\210\\303\\211)\\207 [buffer w3m-modeline-title-timer buffer-live-p nil] 2] (*w3m*) nil 113000] to ([nil 23154 31461 622052 0.5 blink-cursor-timer-function nil nil 870000] [nil 23154 31476 0 60 display-time-event-handler nil nil 0] [nil 23154 31747 353232 300 savehist-autosave nil nil 708000]) while checking timers") > > The behavior differs slightly from those seen earlier because the > timer list contains only three timers when it tries to add another > one. Still the conjecture that we try to add a timer while checking > timers has been proven. I'd love to see a C-level backtrace from that situation, because I'm not really sure what exactly happens and how. > So it seems that we do something we are supposed to avoid - call Lisp > from asynchronous redisplay as a consequence of some mouse movement > (presumably). "Asynchronous redisplay" could only mean the call to expose_frame, is that right? I'm not aware of any other asynchronous entry to redisplay. We could call expose_frame asynchronously if a mouse movement caused the SIGIO signal be delivered to Emacs while copy-sequence did its job. The SIGIO handler then could call gobble_input, which would read the X events from the socket, see the Expose event and call expose_frame, or see the MotionNotify event and call note_mouse_highlight. However, neither of these is supposed to call Lisp, or evaluate the mode-line format (which would call Lisp via :eval), or at least I couldn't see any such call. Both expose_frame and note_mouse_highlight just redraw the glyphs that are already computed by the previous redisplay cycle. So I'm still unsure what is going on here. But if indeed the above scenario somehow ends up calling Lisp from the async redisplay, wrapping the call to Fcopy_sequence in timer_check with block_input and unblock_input should solve the problem, right? Thanks.