From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: martin rudalics Newsgroups: gmane.emacs.bugs Subject: bug#39977: 28.0.50; Unhelpful stack trace Date: Mon, 16 Mar 2020 10:24:14 +0100 Message-ID: References: <83zhcs80e5.fsf@gnu.org> <83imj88tpt.fsf@gnu.org> <550fbc22-09db-d30b-c194-8f26b5dca05f@gmx.at> <83wo7o6nxs.fsf@gnu.org> <60dd4ced-a2e5-ed17-0570-b7bdd2a557af@gmx.at> <83blozckn2.fsf@gnu.org> <01305dbc-c69b-baf9-f0bf-1e5b8c04d970@gmx.at> <83y2s2bswl.fsf@gnu.org> <3ac189d0-5d05-fdf9-0922-0c464b1b17c3@gmx.at> <83k13lbgux.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="100078"; mail-complaints-to="usenet@ciao.gmane.io" Cc: enometh@meer.net, 39977@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Mon Mar 16 11:05:27 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 1jDmch-000PoE-B4 for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 16 Mar 2020 11:05:27 +0100 Original-Received: from localhost ([::1]:36470 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jDmcf-00047k-Ks for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 16 Mar 2020 06:05:26 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:32890) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jDlzb-0008B8-Vw for bug-gnu-emacs@gnu.org; Mon, 16 Mar 2020 05:25:05 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1jDlza-0002Q0-LF for bug-gnu-emacs@gnu.org; Mon, 16 Mar 2020 05:25:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:58321) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1jDlza-0002P5-Gk for bug-gnu-emacs@gnu.org; Mon, 16 Mar 2020 05:25:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1jDlza-0004d8-DT for bug-gnu-emacs@gnu.org; Mon, 16 Mar 2020 05:25:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: martin rudalics Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 16 Mar 2020 09:25:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 39977 X-GNU-PR-Package: emacs Original-Received: via spool by 39977-submit@debbugs.gnu.org id=B39977.158435067017712 (code B ref 39977); Mon, 16 Mar 2020 09:25:02 +0000 Original-Received: (at 39977) by debbugs.gnu.org; 16 Mar 2020 09:24:30 +0000 Original-Received: from localhost ([127.0.0.1]:36051 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jDlz4-0004bc-1W for submit@debbugs.gnu.org; Mon, 16 Mar 2020 05:24:30 -0400 Original-Received: from mout.gmx.net ([212.227.15.18]:36457) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jDlz2-0004bP-A5 for 39977@debbugs.gnu.org; Mon, 16 Mar 2020 05:24:28 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1584350657; bh=T3ihwJSd3VmqtX20Ce+cjBpgzymnGQyeVAJnNqBL69Q=; h=X-UI-Sender-Class:Subject:To:Cc:References:From:Date:In-Reply-To; b=IW/fNAjarp8Jc3GtpqilpB8BnKwM+WWFrhF2UWYk3wqfVAG72oWFdxRtXOMhKQr/J oT/DLFTqmVsJ2Lm/Tk8d1vp9J8ddz2i20NREtrqWMjXMAW2t17qoN9z4Rn0IqBDssP eoBM+JV5YhrG395i+EiAvKKexi1EWww+s3Vf+/PY= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Original-Received: from [192.168.1.101] ([212.95.5.221]) by mail.gmx.com (mrgmx005 [212.227.17.190]) with ESMTPSA (Nemesis) id 1MMofW-1iv06u3fFM-00Inx4; Mon, 16 Mar 2020 10:24:16 +0100 In-Reply-To: <83k13lbgux.fsf@gnu.org> Content-Language: en-US X-Provags-ID: V03:K1:cx+loIlLWwtBdqRkwdUmLhCQGsa2JasHCUZZUpP1N43SvX8K2ur sRRID+fuCcnpdGxMdquNsEBShVRn5UODRtGtKgA9gkav7aq1pgPQ6OHeyeLD/0EyQ5L16qH WR1ZEGe7mNKgu6kVGhKzDSyX462ehew8F3BsD5SsCha1rgpWL6FEyAYvAbhu4Sra49l6W2n 6qNUoQllD9+jsH3FX8TSg== X-UI-Out-Filterresults: notjunk:1;V03:K0:iwjGOPIDbBg=:yaiA1JeAdbRKtPRD/oOuX+ 02vCdWi1PN9flJyhnf2lxR560sTwYJAQc/dHsV4N9ChMf1pmyCU0ESFx24/jBj4C4J92blIoh 8H5EgrZNgxStDy5SVu8+/b8LcmSSFoRO/siU8f6+5Q/alkOYAwbi+dOseupNYiqlcEgaOogJo EVQ8Ok92PpQpj7QSBxnv3XpJ2I0zm926SSgTYlC7EFBtWddhoD+0owHsX9irDvp+hF8pZbMB3 fLBSmDnWTHerA484GSLzkQJnbkxw4QFyLUEbyrVLA+8eouUziEjtI0m2yaCZW585YYGq8svrE 3x3luPCsQ00vPnydC8KNJd6lipj0RYbKyXqH1xa/TeLzgQsnxlZb2s+4YkzgoOo8uKWkg1I49 n4oJnyS4AKq8+OKQQj+39bVYUGTa2LVEvvqjapQcrms6NGMY54FeFodvJdUcAclwOLMusachY J+MeU62DjuYyPS5iAG5YYdnN1e4giRayRg3Li6KtOhFlAqVUaJEwicJi1h0z9+6i/q4TuGMwA 58qSVbP0IcuCEgIyzpD/CJDaznnQr9G9XEJ+GSxPP+Ds5CQyFcqoor5xUyqEQcm5LF89/wgEY yAILiE1ZlyDoxg1mtK1YLCSTs55Q7q623398cqa5sfPONZ+Cfb8fKOTSWF7rgbZcAL8rZD0PU QgcuSD2SuFU8vzDyqOZlHp/nQOBq1o2JqW+HmG9zrggUUnZPsK7Hd9sfyJGwe4/hFuEI5b9h/ Ignevr3GLlau4DlQefIU9yL/EVfwe2L10/RlXbqa4XfngtECZj940ZK2NWQIb399xMqzcz9m 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-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:177407 Archived-At: >> As far as xdisp.c is concerned it simply must not set selected_frame >> to a dead frame. > > I don't think that's possible in xdisp.c cases you've shown. > >> Never ever. > > Why not? Because it might shift the abort to the next instance of SELECTED_FRAME. >> As far as frame.c is concerned, it should do something like in the >> attached patch. > > We cannot punt like that in the display engine. Why not? At least one of the frame restorations is unprotected anyway and might leave the temporarily selected frame selected. > So you are saying that selecting such a frame will cause trouble to > some other code, not to the display engine? Not "will" but "may". The problem is that it then might be harder to find the cause. With emacs -Q evaluate (defvar foo '(:eval (when (> (length (frame-list)) 1) (delete-frame (next-frame))))) (setq-default mode-line-format foo) and do C-x 5 2. The backtrace I get here is #0 0x000000000063f7a3 in terminate_due_to_signal (sig=6, backtrace_limit=40) at ../../src/emacs.c:371 #1 0x000000000068ac8a in emacs_abort () at ../../src/sysdep.c:2448 #2 0x00000000004ee088 in select_window (window=XIL(0x1be5745), norecord=XIL(0x30), inhibit_point_swap=false) at ../../src/window.c:544 #3 0x00000000004ee2f9 in Fselect_window (window=XIL(0x1be5745), norecord=XIL(0x30)) at ../../src/window.c:630 #4 0x0000000000484c33 in gui_consider_frame_title (frame=XIL(0x1be5505)) at ../../src/xdisp.c:12318 #5 0x00000000004974b6 in redisplay_window (window=XIL(0x1be5745), just_this_one_p=false) at ../../src/xdisp.c:18940 #6 0x000000000048cb00 in redisplay_window_0 (window=XIL(0x1be5745)) at ../../src/xdisp.c:16179 #7 0x00000000007b10dd in internal_condition_case_1 (bfun=0x48cabe , arg=XIL(0x1be5745), handlers=XIL(0x7ffff40bafbb), hfun=0x48ca86 ) at ../../src/eval.c:1379 #8 0x000000000048ca58 in redisplay_windows (window=XIL(0x1be5745)) at ../../src/xdisp.c:16159 #9 0x000000000048b486 in redisplay_internal () at ../../src/xdisp.c:15627 #10 0x0000000000489084 in redisplay () at ../../src/xdisp.c:14854 #11 0x0000000000650828 in read_char (commandflag=1, map=XIL(0x17ce993), prev_event=XIL(0), used_mouse_menu=0x7fffffffe13f, end_time=0x0) at ../../src/keyboard.c:2493 #12 0x0000000000663705 in read_key_sequence (keybuf=0x7fffffffe2d0, prompt=XIL(0), dont_downcase_last=false, can_return_switch_frame=true, fix_current_buffer=true, prevent_redisplay=false) at ../../src/keyboard.c:9549 #13 0x000000000064ccee in command_loop_1 () at ../../src/keyboard.c:1350 #14 0x00000000007b1002 in internal_condition_case (bfun=0x64c872 , handlers=XIL(0x90), hfun=0x64be81 ) at ../../src/eval.c:1355 #15 0x000000000064c457 in command_loop_2 (ignore=XIL(0)) at ../../src/keyboard.c:1091 #16 0x00000000007b04b6 in internal_catch (tag=XIL(0xd0e0), func=0x64c42a , arg=XIL(0)) at ../../src/eval.c:1116 #17 0x000000000064c3f5 in command_loop () at ../../src/keyboard.c:1070 #18 0x000000000064b968 in recursive_edit_1 () at ../../src/keyboard.c:714 #19 0x000000000064bb60 in Frecursive_edit () at ../../src/keyboard.c:786 #20 0x0000000000641f98 in main (argc=2, argv=0x7fffffffe7c8) at ../../src/emacs.c:2035 which is almost the same as Madhu's. So maybe the display engine should simply set a global boolean inhibit_frame_changes while evaluating mode lines or frame titles and have at least delete_frame not delete a frame when that variable is set. If we decide that fixing such a problem is urgent. martin