From unknown Sun Aug 10 16:51:42 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#31312 <31312@debbugs.gnu.org> To: bug#31312 <31312@debbugs.gnu.org> Subject: Status: Segmentation fault with doom-emacs, NeoTree and Zoom Reply-To: bug#31312 <31312@debbugs.gnu.org> Date: Sun, 10 Aug 2025 23:51:42 +0000 retitle 31312 Segmentation fault with doom-emacs, NeoTree and Zoom reassign 31312 emacs submitter 31312 Andrea Cardaci severity 31312 normal tag 31312 confirmed fixed thanks From debbugs-submit-bounces@debbugs.gnu.org Sun Apr 29 13:00:27 2018 Received: (at submit) by debbugs.gnu.org; 29 Apr 2018 17:00:27 +0000 Received: from localhost ([127.0.0.1]:43085 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fCpgW-0007dO-MU for submit@debbugs.gnu.org; Sun, 29 Apr 2018 13:00:25 -0400 Received: from eggs.gnu.org ([208.118.235.92]:56435) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fCk0o-00082O-Ee for submit@debbugs.gnu.org; Sun, 29 Apr 2018 06:56:58 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fCk0i-0005jb-46 for submit@debbugs.gnu.org; Sun, 29 Apr 2018 06:56:53 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50,FREEMAIL_FROM, HTML_MESSAGE,T_DKIM_INVALID autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:53238) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1fCk0i-0005jX-0I for submit@debbugs.gnu.org; Sun, 29 Apr 2018 06:56:52 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:47399) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fCk0g-0000j9-Id for bug-gnu-emacs@gnu.org; Sun, 29 Apr 2018 06:56:51 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fCk0f-0005ir-MA for bug-gnu-emacs@gnu.org; Sun, 29 Apr 2018 06:56:50 -0400 Received: from mail-qt0-x22b.google.com ([2607:f8b0:400d:c0d::22b]:43535) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1fCk0f-0005ii-H0 for bug-gnu-emacs@gnu.org; Sun, 29 Apr 2018 06:56:49 -0400 Received: by mail-qt0-x22b.google.com with SMTP id l11-v6so7790817qtj.10 for ; Sun, 29 Apr 2018 03:56:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:from:date:message-id:subject:to; bh=BpZ9lLmQCMBB2Xw/PCQ2m/qlznH+spv3696GBNGRjbQ=; b=uaaCMapuDcY9+vc9ac3i7S8avPrUdMp39CFsXY8vPh6z9ziJoRbTFjFZ8duj2kdJ/+ /FWtPwIAVOVkeV77Fihnb87iTjzHCbrw3iqy4a/wnyn0jpK3KYgJ+ky3H+4NcbItzum0 jtyhSrHD+Jg1aIWcP6OmmFUy1rHho0ZbxgwmCUDup4/7ysP9Ga6ARCR21mRIJHgyFnd8 FjxhzMIpFm3Ae6zd6qlcQyQxKz7jR099IXiSaD/rK92aPX9JhuVFFp0NBk1tpxVeDbfY Mp9JQAS7BB7l2yGn1mn5jKFJuozXHTsyysAaQJ6y6zPvIl7VCfGBvRQDIKXvcqy9B4kW WdwQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=BpZ9lLmQCMBB2Xw/PCQ2m/qlznH+spv3696GBNGRjbQ=; b=CCGPiU5mHrWBsClix7fEQpKW6g+cQIpBasOGoU5BWHtg4O18XMOo68vLcapVbUWsva 2x/1Ng0xIFQFur277iNBz94TQwsRQXmmZhIA5GjPHYZGnmJjLHTYkyW3ujH2YhTzJVY/ e0w+izKe/kqaTGDbmTjlKaUz79YsHE6hKJyv5K0yx3gN7c5ZnVNzU5jwxDqGW8AikO9J +eKxPr2t4feTsZPrRG0xaC39fIF3E5gQtg1BkVrhzXtG3slCapz+wiP7dlDG0t6ScD7K XTnw5SYtqYXzPstR2Btc3j83chWa8ECqqoY326Dqsu7oWyYPyTP3ji4qjAOnHjLjELMl P2Rg== X-Gm-Message-State: ALQs6tBIT9uwffiktoRnaK95osVH8mXxvsNCzNpjhIL8FZyIp3p738QM i78J28Qt/sLBq5rABJdQe3qiZ2u+vNTqfPCsypPEdAI8 X-Google-Smtp-Source: AB8JxZpGjUpL6opaXgELV3MqZZi2hu2KhPIY3gQ9PlYyWOwgbBJ2BHTpHA2Kahn5fx31l+wva8prjSc/PxNQZFXBc1A= X-Received: by 2002:aed:3595:: with SMTP id c21-v6mr8201602qte.203.1524999408516; Sun, 29 Apr 2018 03:56:48 -0700 (PDT) MIME-Version: 1.0 Received: by 10.200.63.210 with HTTP; Sun, 29 Apr 2018 03:56:47 -0700 (PDT) From: Andrea Cardaci Date: Sun, 29 Apr 2018 12:56:47 +0200 Message-ID: Subject: Segmentation fault with doom-emacs, NeoTree and Zoom To: bug-gnu-emacs@gnu.org Content-Type: multipart/alternative; boundary="00000000000007052a056afa985d" X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 2001:4830:134:3::11 X-Spam-Score: -4.0 (----) X-Debbugs-Envelope-To: submit X-Mailman-Approved-At: Sun, 29 Apr 2018 13:00:23 -0400 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -5.0 (-----) --00000000000007052a056afa985d Content-Type: text/plain; charset="UTF-8" Hello, Someone filed a bug for my repo (https://github.com/cyrus-and/zoom/issues/20) but I'm pretty sure it's a bug in Emacs. Unfortunately the steps to reproduce it involve setting up `doom-emacs` which is quite cumbersome. You can find all the details at the above link but in short using `doom-emacs` with Zoom and NeoTree crashes Emacs with a segmentation fault. I apologize for the low quality of this bug report, but I think that's better than nothing. Andrea --00000000000007052a056afa985d Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Hello,

Someone filed a bug for my repo = (https://github.com/cyrus-and/zoom/issues/20) but I'm= pretty sure it's a bug in Emacs. Unfortunately the steps to reproduce = it involve setting up `doom-emacs` which is quite cumbersome.
You can find all the details at the above link but in short usi= ng `doom-emacs` with Zoom and NeoTree crashes Emacs with a segmentation fau= lt.

I apologize for the low quality of this bug re= port, but I think that's better than nothing.

=
Andrea



--00000000000007052a056afa985d-- From debbugs-submit-bounces@debbugs.gnu.org Tue May 01 09:26:09 2018 Received: (at 31312) by debbugs.gnu.org; 1 May 2018 13:26:09 +0000 Received: from localhost ([127.0.0.1]:44824 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fDVIH-0004zP-AW for submit@debbugs.gnu.org; Tue, 01 May 2018 09:26:09 -0400 Received: from mail-it0-f43.google.com ([209.85.214.43]:37514) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fDVIE-0004z6-VJ; Tue, 01 May 2018 09:26:07 -0400 Received: by mail-it0-f43.google.com with SMTP id 70-v6so7216348ity.2; Tue, 01 May 2018 06:26:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=dYOSWb9/4QZrgs/acWn3YsgzqQbS3cl18oqqakZvDCI=; b=HRxQpzFS9uGmxjBgthSw2mPAZrOqyJ7iQBEk/WsXWtN+f2F3NNVhQK9AB+IDl4sA03 Jzfl9SMs0qUBHbvnnV2EDTWcNuPS8UbnKrqf2hYIiOX3SSpdPZ0H62sOgxWQxQZcgGcE SLz9Cb4ED2I2FpwsQOwRcVv8R31awu6mVWPY5JcslcUAmTD4VQ1fk0BVCNuXrTIqSGNV MnVIdFuPfltJskYwSLwr9vCbQGPORov5BGu4xF8pePjcZeV9Gy7BtTfbpIrVs0OARJjC PAd1gWsAJx53miuG+ZxUcfBtKy3VaEdZB6j0djlmu3lAclPXJaRv+vAbGc9Qn2+knHhZ Sj1Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=dYOSWb9/4QZrgs/acWn3YsgzqQbS3cl18oqqakZvDCI=; b=uTlFcfKXvyRv4z74qg1OBZi6tpzwD/gMpjJ9zU3vDcyQMnf96RDyJ34A2mpmMWj26M I4MAOW3l/mXDLhZq5CzdSU1ahuB98p6+4ydd+PdeaRfmturk6J0+RhnE2DBPFvFrolh9 2P4Sk/vzcUKsmMpPbP4QsY7HBoVpPcnapIa9EMp/+KLDf2g1o8I7Ted0YCwlWJnNkK9s YTI/IqQkNeqkH5En1JiQ8HU7+zRkAqZN+749SQ3TxB4NCNCAYcEphH22fV43FX+pO3jY RUE3FsWzxVBHa1/gKQ1yVLlRrYrKrI7iw6iAstUEZyboX6jArHu66DfMZjkO+W1eRkaM Ucsg== X-Gm-Message-State: ALQs6tCxJ/UojrSsxuQ53/nN/ZH2jQC6II7kgEh4boFCH5I47ppu3OHA O7ayXVN19i2aHtb2HwMF0ZISZA== X-Google-Smtp-Source: AB8JxZqSlJ1lzAPmreikm+Wtwl5RYh/Gdr0/sJhudWdgEK2qssjbfn230/p13CTupcz0GnkfW94aew== X-Received: by 2002:a24:114f:: with SMTP id 76-v6mr16724472itf.75.1525181161333; Tue, 01 May 2018 06:26:01 -0700 (PDT) Received: from zebian (cbl-45-2-119-34.yyz.frontiernetworks.ca. [45.2.119.34]) by smtp.googlemail.com with ESMTPSA id v127-v6sm1021775itc.3.2018.05.01.06.26.00 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 01 May 2018 06:26:00 -0700 (PDT) From: Noam Postavsky To: Andrea Cardaci Subject: Re: bug#31312: Segmentation fault with doom-emacs, NeoTree and Zoom References: Date: Tue, 01 May 2018 09:25:59 -0400 In-Reply-To: (Andrea Cardaci's message of "Sun, 29 Apr 2018 12:56:47 +0200") Message-ID: <87r2mvo6c8.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.0 (/) X-Debbugs-Envelope-To: 31312 Cc: 31312@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) tags 31312 + confirmed found 31312 26.1 quit Andrea Cardaci writes: > Someone filed a bug for my repo (https://github.com/cyrus-and/zoom/issues/20) > but I'm pretty sure it's a bug in Emacs. Unfortunately the steps to > reproduce it involve setting up `doom-emacs` which is quite cumbersome. > > You can find all the details at the above link but in short using > `doom-emacs` with Zoom and NeoTree crashes Emacs with a segmentation fault. Reproduced with emacs-26, seems there is a window without a buffer. ../../src/buffer.h:914: Emacs fatal error: assertion failed: BUFFERP (a) Thread 1 "emacs" hit Breakpoint 1, terminate_due_to_signal (sig=6, backtrace_limit=2147483647) at ../../src/emacs.c:364 364 signal (sig, SIG_DFL); (gdb) bt #0 terminate_due_to_signal (sig=6, backtrace_limit=2147483647) at ../../src/emacs.c:364 #1 0x0000000000614655 in die (msg=0x74ecf9 "BUFFERP (a)", file=0x74ece6 "../../src/buffer.h", line=914) at ../../src/alloc.c:7423 #2 0x000000000057a1a8 in XBUFFER (a=XIL(0)) at ../../src/buffer.h:914 #3 0x0000000000464716 in reconsider_clip_changes (w=0x60537f0) at ../../src/xdisp.c:13727 #4 0x000000000046514d in redisplay_internal () at ../../src/xdisp.c:13939 #5 0x0000000000463c16 in redisplay () at ../../src/xdisp.c:13518 #6 0x00000000005851ae in read_char (commandflag=1, map=XIL(0x5cf7503), prev_event=XIL(0), used_mouse_menu=0x7fffffffe41f, end_time=0x0) at ../../src/keyboard.c:2480 #7 0x00000000005957c5 in read_key_sequence (keybuf=0x7fffffffe570, bufsize=30, prompt=XIL(0), dont_downcase_last=false, can_return_switch_frame=true, fix_current_buffer=true, prevent_redisplay=false) at ../../src/keyboard.c:9147 #8 0x0000000000581d55 in command_loop_1 () at ../../src/keyboard.c:1368 #9 0x0000000000638529 in internal_condition_case (bfun=0x581909 , handlers=XIL(0x5250), hfun=0x580f4c ) at ../../src/eval.c:1332 #10 0x0000000000581524 in command_loop_2 (ignore=XIL(0)) at ../../src/keyboard.c:1110 #11 0x0000000000637a32 in internal_catch (tag=XIL(0xc6f0), func=0x5814f7 , arg=XIL(0)) at ../../src/eval.c:1097 #12 0x00000000005814c2 in command_loop () at ../../src/keyboard.c:1089 #13 0x0000000000580a36 in recursive_edit_1 () at ../../src/keyboard.c:695 #14 0x0000000000580c2b in Frecursive_edit () at ../../src/keyboard.c:766 #15 0x000000000057e7c6 in main (argc=1, argv=0x7fffffffea38) at ../../src/emacs.c:1713 (gdb) frame 3 #3 0x0000000000464716 in reconsider_clip_changes (w=0x60537f0) at ../../src/xdisp.c:13727 13727 struct buffer *b = XBUFFER (w->contents); (gdb) p w->contents $1 = XIL(0) From debbugs-submit-bounces@debbugs.gnu.org Tue May 01 10:33:25 2018 Received: (at 31312) by debbugs.gnu.org; 1 May 2018 14:33:25 +0000 Received: from localhost ([127.0.0.1]:45767 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fDWLN-0002I4-Jh for submit@debbugs.gnu.org; Tue, 01 May 2018 10:33:25 -0400 Received: from mout.gmx.net ([212.227.17.20]:39799) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fDWLK-0002Hp-FJ for 31312@debbugs.gnu.org; Tue, 01 May 2018 10:33:23 -0400 Received: from [192.168.1.100] ([212.95.5.72]) by mail.gmx.com (mrgmx103 [212.227.17.168]) with ESMTPSA (Nemesis) id 0Lrw2c-1eDOzd0Mu6-013fR2; Tue, 01 May 2018 16:33:15 +0200 Message-ID: <5AE87AA3.6050602@gmx.at> Date: Tue, 01 May 2018 16:33:07 +0200 From: martin rudalics MIME-Version: 1.0 To: Noam Postavsky , Andrea Cardaci Subject: Re: bug#31312: Segmentation fault with doom-emacs, NeoTree and Zoom References: <87r2mvo6c8.fsf@gmail.com> In-Reply-To: <87r2mvo6c8.fsf@gmail.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Provags-ID: V03:K1:RjLIHMe1l/1J93YTRrjw7O3s9EF1hsRHz3wMyGmF4JciZD/9E+D nZNs/GdJMXLL31l+ttuwX5uIfLE+YeCHTh4eJ6svLisFbWg5yRc9N5zdYYq2XGSwqgQ5tn2 Q9GuTw4DvmGven5VZVegOsJXtCruHvhuhrVimUwrl1HzeM9QLiwz+iBeRs2a0xeabZTjm6T pjOTnNnvD+4FN1Bmvf1iQ== X-UI-Out-Filterresults: notjunk:1;V01:K0:dlFaC+dRd3U=:4C60WFesQ1ZEbO17PUEl2W wqv4ulgn8zSJTlAjTSg6dKtLaI7h8gEBxDgbe+YkzYq5djaB6CLi7vAB0zFe5BJSkiuInRd2q vX/RjUuoZ4pgHTICp6EcdgebrcSbhoY8zVsOy97cEhtJfvAo4/FOman/+EFKmgbQmfKUHWOwz 2mZxjXwWiE6WErQT7+Dmwy7LghNyugK6ipeuI8E+STbhDrbVJLr+d28V4M+OFOcQYWs2UJPYI BHYdlmbpg7gxgRGMdiyl4c0BC3sltExI2adeH3muGaXNZbifzYTyX8Wj74PUqzGvw3zn10uN7 UuYCZv2Syybq6XI7kQ+0iajAsawqUBcpxjYJ5xFdM/JoJt6DwkVPHirSLoOLfIa6jDFmyVd5B p9rhI+hrw5t4zU4viXgdi/5dVtR6ArLdZog4/jOVImu4BkT7cQR5GaEhlg8WK3a/XBHqrIVS+ TiINpdyv1UruoPfo9h0S5g3sBjRvB1Kn+6XTrEs2Rg2VtxqmHNsyQbKTlO8Fv3HtUChmpF4sy gkvQ5OAL4lVMlwOJM0Tg0l79k+GSaZO7w45M/Dwdgr+ruY55T2Rgjvt0kmphn0rK0nPgW42kF icKayUU+/HmBOpb37o2905LQrIitUfliZUECDhhFmnlNFkdd37pc50403BBR+12pr3THWF3wX s16sbtJKLcH5EkaRDe9ScWzFiTnJE6piWuypj61eHAwrMiSLQqTZ5vav9YkZB0tPvrfd5FM1f exJtqEWcREFMSHUt0xtdY46dAl9EF/fjEoOzxVeJjcnvd9M4d2cIDOStXwPGmOQ02+ZAQK9aD 0r94te8 X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 31312 Cc: 31312@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) > Reproduced with emacs-26, seems there is a window without a buffer. > > ../../src/buffer.h:914: Emacs fatal error: assertion failed: BUFFERP (a) > > Thread 1 "emacs" hit Breakpoint 1, terminate_due_to_signal (sig=6, backtrace_limit=2147483647) > at ../../src/emacs.c:364 > 364 signal (sig, SIG_DFL); > (gdb) bt > #0 terminate_due_to_signal (sig=6, backtrace_limit=2147483647) at ../../src/emacs.c:364 > #1 0x0000000000614655 in die (msg=0x74ecf9 "BUFFERP (a)", file=0x74ece6 "../../src/buffer.h", > line=914) at ../../src/alloc.c:7423 > #2 0x000000000057a1a8 in XBUFFER (a=XIL(0)) at ../../src/buffer.h:914 > #3 0x0000000000464716 in reconsider_clip_changes (w=0x60537f0) at ../../src/xdisp.c:13727 > #4 0x000000000046514d in redisplay_internal () at ../../src/xdisp.c:13939 > #5 0x0000000000463c16 in redisplay () at ../../src/xdisp.c:13518 > #6 0x00000000005851ae in read_char (commandflag=1, map=XIL(0x5cf7503), prev_event=XIL(0), > used_mouse_menu=0x7fffffffe41f, end_time=0x0) at ../../src/keyboard.c:2480 > #7 0x00000000005957c5 in read_key_sequence (keybuf=0x7fffffffe570, bufsize=30, prompt=XIL(0), > dont_downcase_last=false, can_return_switch_frame=true, fix_current_buffer=true, > prevent_redisplay=false) at ../../src/keyboard.c:9147 > #8 0x0000000000581d55 in command_loop_1 () at ../../src/keyboard.c:1368 > #9 0x0000000000638529 in internal_condition_case (bfun=0x581909 , > handlers=XIL(0x5250), hfun=0x580f4c ) at ../../src/eval.c:1332 > #10 0x0000000000581524 in command_loop_2 (ignore=XIL(0)) at ../../src/keyboard.c:1110 > #11 0x0000000000637a32 in internal_catch (tag=XIL(0xc6f0), func=0x5814f7 , arg=XIL(0)) > at ../../src/eval.c:1097 > #12 0x00000000005814c2 in command_loop () at ../../src/keyboard.c:1089 > #13 0x0000000000580a36 in recursive_edit_1 () at ../../src/keyboard.c:695 > #14 0x0000000000580c2b in Frecursive_edit () at ../../src/keyboard.c:766 > #15 0x000000000057e7c6 in main (argc=1, argv=0x7fffffffea38) at ../../src/emacs.c:1713 > (gdb) frame 3 Is w in reconsider_clip_changes the same as XWINDOW (selected_window) when it fails? If so, could you instrument select_window_1 (or use a watchpoint) to check whether selected_window = window ever assigns a window with XWINDOW (window)->contents equal Qnil? Thanks, martin From debbugs-submit-bounces@debbugs.gnu.org Tue May 01 19:10:27 2018 Received: (at 31312) by debbugs.gnu.org; 1 May 2018 23:10:27 +0000 Received: from localhost ([127.0.0.1]:46177 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fDePj-0003UJ-6k for submit@debbugs.gnu.org; Tue, 01 May 2018 19:10:27 -0400 Received: from mail-io0-f178.google.com ([209.85.223.178]:33910) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fDePh-0003U7-De for 31312@debbugs.gnu.org; Tue, 01 May 2018 19:10:25 -0400 Received: by mail-io0-f178.google.com with SMTP id p124-v6so15378563iod.1 for <31312@debbugs.gnu.org>; Tue, 01 May 2018 16:10:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=+SmnBJz3YTzd+HvtRZU9AAaHnp32fb3/VAUAZDxwDJQ=; b=B9vwAlL5uDgsycRlaeuVjYQcp09oabQl9/pU3lBoPcntAMMn8QzkBBckYmOh9YtS1S U7uARhBOoQrvfN0DGJcyKLnKbdb8Vk6bXo+V6OuBnCV4dOUqTZWZsL0rNHBunxLGb1+i /S1uNRoi7r7lfEHISY3u49YkoHqPSw1B7H7SejMBEAeojGDmJmVe2cP5k6SSVgewhBx+ YI3Yxz12Vakwm7DM6tAwcGj8nxfampV/JrOWQjPlEFJjz8e+r+MJVePtbyYgl9En94JC H8Tq3J0VP0AhX97XnJP43mKKm3YDi/Fj5pQ2xdtSurxM1ozodp0i/AfFlh7QV/xRH0Bt BK8w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=+SmnBJz3YTzd+HvtRZU9AAaHnp32fb3/VAUAZDxwDJQ=; b=de3cNH0MgCwLBxD2SXNguZUJ8FDxeA86wweKL82KmNw2uunr8cgQWujKM1CrotasZA EnFI/FBpCIcqd8bKTQbjUF1ZsYU6UPgdX8c5OLyT2F8O0ngl8zIriXLDDFanFgLVJo3g KqNLSH1K+RuHXVURpg3aZi+YSCljsDx1Hp0Tg3YuttVSFI6kHXSmgHHP5iALfJijiOr2 uRMZbuYtA1vGUyc4JCrCrz1BHLktSGkI2gGp36in6Mh/E3uug2jXlLMkgk/ZB9BEYJma bXwo/a6cFtyACwuvNnW2/pOjaCJqW16nzRQThWSM1kBn+D7vaYZxQFzvsTgkpSB3NXDe 7KsQ== X-Gm-Message-State: ALQs6tADM3L2Tr31MbuhAt9HddrCfa3qy0FKXaxC4Yk+dv93kXvRPCG2 0YjowRKuBzfiBbFn7WTT2ZqALA== X-Google-Smtp-Source: AB8JxZpAfAXwoUsYdu86xOLZeAziCtbKrmqPjiW8GnqIccLX8lNvoOxbZgF1HmTEZ1tADn2SmLLRYQ== X-Received: by 2002:a6b:298f:: with SMTP id p137-v6mr19208885iop.288.1525216219774; Tue, 01 May 2018 16:10:19 -0700 (PDT) Received: from zebian (cbl-45-2-119-34.yyz.frontiernetworks.ca. [45.2.119.34]) by smtp.googlemail.com with ESMTPSA id g62-v6sm5719960ioj.17.2018.05.01.16.10.17 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 01 May 2018 16:10:18 -0700 (PDT) From: Noam Postavsky To: martin rudalics Subject: Re: bug#31312: Segmentation fault with doom-emacs, NeoTree and Zoom References: <87r2mvo6c8.fsf@gmail.com> <5AE87AA3.6050602@gmx.at> Date: Tue, 01 May 2018 19:10:09 -0400 In-Reply-To: <5AE87AA3.6050602@gmx.at> (martin rudalics's message of "Tue, 01 May 2018 16:33:07 +0200") Message-ID: <87o9hznfam.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 31312 Cc: 31312@debbugs.gnu.org, Andrea Cardaci X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) martin rudalics writes: > Is w in reconsider_clip_changes the same as XWINDOW (selected_window) > when it fails? Nope. In fact, doing break 13939 if (w != XWINDOW(selected_window)) triggers only just before the bad reconsider_clip_changes call. #0 redisplay_internal () at ../../src/xdisp.c:13939 #1 0x0000000000463c16 in redisplay () at ../../src/xdisp.c:13518 #2 0x00000000005851ae in read_char (commandflag=1, map=XIL(0x5e99db3), prev_event=XIL(0), used_mouse_menu=0x7fffffffe41f, end_time=0x0) at ../../src/keyboard.c:2480 #3 0x00000000005957c5 in read_key_sequence (keybuf=0x7fffffffe570, bufsize=30, prompt=XIL(0), dont_downcase_last=false, can_return_switch_frame=true, fix_current_buffer=true, prevent_redisplay=false) at ../../src/keyboard.c:9147 #4 0x0000000000581d55 in command_loop_1 () at ../../src/keyboard.c:1368 (More stack frames follow...) (gdb) p w $16 = (struct window *) 0x47d22f0 (gdb) p sw $17 = (struct window *) 0x47d22f0 (gdb) p XWINDOW(selected_window) $18 = (struct window *) 0x61109d0 (gdb) p w->contents $19 = XIL(0) (gdb) p XWINDOW(selected_window)->contents $20 = XIL(0x493e565) (gdb) xpr Lisp_Vectorlike PVEC_BUFFER $21 = (struct buffer *) 0x493e560 (unsigned char *) 0x4a34568 " *NeoTree*" From debbugs-submit-bounces@debbugs.gnu.org Wed May 02 02:16:45 2018 Received: (at 31312) by debbugs.gnu.org; 2 May 2018 06:16:45 +0000 Received: from localhost ([127.0.0.1]:46338 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fDl4G-0005MI-Vh for submit@debbugs.gnu.org; Wed, 02 May 2018 02:16:45 -0400 Received: from mout.gmx.net ([212.227.17.21]:41357) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fDl4D-0005M2-0L for 31312@debbugs.gnu.org; Wed, 02 May 2018 02:16:41 -0400 Received: from [192.168.1.101] ([213.162.73.252]) by mail.gmx.com (mrgmx103 [212.227.17.168]) with ESMTPSA (Nemesis) id 0MdaiW-1ezNS20d7E-00PQsy; Wed, 02 May 2018 08:16:34 +0200 Message-ID: <5AE957BA.6000809@gmx.at> Date: Wed, 02 May 2018 08:16:26 +0200 From: martin rudalics MIME-Version: 1.0 To: Noam Postavsky Subject: Re: bug#31312: Segmentation fault with doom-emacs, NeoTree and Zoom References: <87r2mvo6c8.fsf@gmail.com> <5AE87AA3.6050602@gmx.at> <87o9hznfam.fsf@gmail.com> In-Reply-To: <87o9hznfam.fsf@gmail.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Provags-ID: V03:K1:vGUFGKvIP4qSS7c2/svFIFi15Bz4RbPr85F0af8oN770KDqHmv5 phBPzr/oIzpSBAVq8CokRjT2DoYMKlBlaISLiYZaZFjE9cBAHfTpssa2sz3pIToLoSjGhyo q9j6xzzrVT0cBWAiYIELHUflQQNPxnSsAYiQsueaUbnPBhC4SNqYBjxmUt6rlasDnzrC8jM RMos0zGlTaWRepv6g29hw== X-UI-Out-Filterresults: notjunk:1;V01:K0:0wwKw8NqMAI=:/4l9NzeJpRPh4tIhj2qgGl orixbG++N4uczDBSMOxq0LVi/VBvteB47esiq468v+JxDu10xZrmsh4YYZrT9EYpaNFa+Uarx KQozDRE7b8i5xsqnlHMaOclSpcD0Nu+nWRRk3BCJw30JLc9CZy8GQRXowMsuwkGDRx0HlFA1K 80GJmia3dW1xVnev/c9caxBJru5R/x3H5s58txjsM4+BDJ1c0TJ9IYfbWgttzIJs9gElAjXu0 P4skoDK8HFseld8JAjN+W74ZBS9YQsXxkQ/hXSUPDPWAAtiXDoENdMhjXgkUwgeqphhaPICK7 Oozb2dRfOcU5vplS+KKTSG7A6nXFq9uJgM/Q0n05slvutcebHL2R6Fm9FgHYNKbwwNJJ2Aaz8 hvd4+lMCx2fLK9KFecyNQqUcknAYugpNKifDwVtnyazG2vJxrgrOL8p7fehqM8hmIApGdzJpO 2g7h7pTmERulJRnXubRKBubzf2LL0klh0iu9OS9kwIA4FdoIok08GiHz4aLKWVndoVa5wFyK1 GR24jwJeflI3IVpKqkBsqzV09dT2fwUlH+m3FPQr1KnJs0fTlz/VaV5KF3wBkZRNxSWhpVzpf vX317l3I9B9B9yQqKbWid6U868dND+DliH3d4sfvB5B4G4AOwzqCWHg8quSoCdv8npXiPRCFc vRbb4q1SDUuoOGdHI7DUAeBplQNT1AALUJWK24C59xBmKYPDyvIICbIi4ZZf7xio2DKbW5yss m5Y5ZBIsAkPzLrIeSn7x2X0DoP8ZJVW1ka69kXyqEK1fYFf/a5ODeOH/Ymw4Mf4J/cvmP58Ip dc5b7O3 X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 31312 Cc: 31312@debbugs.gnu.org, Andrea Cardaci X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) >> Is w in reconsider_clip_changes the same as XWINDOW (selected_window) >> when it fails? > > Nope. In fact, doing > > break 13939 if (w != XWINDOW(selected_window)) > > triggers only just before the bad reconsider_clip_changes call. > > #0 redisplay_internal () at ../../src/xdisp.c:13939 > #1 0x0000000000463c16 in redisplay () at ../../src/xdisp.c:13518 > #2 0x00000000005851ae in read_char (commandflag=1, map=XIL(0x5e99db3), prev_event=XIL(0), > used_mouse_menu=0x7fffffffe41f, end_time=0x0) at ../../src/keyboard.c:2480 > #3 0x00000000005957c5 in read_key_sequence (keybuf=0x7fffffffe570, bufsize=30, prompt=XIL(0), > dont_downcase_last=false, can_return_switch_frame=true, fix_current_buffer=true, > prevent_redisplay=false) at ../../src/keyboard.c:9147 > #4 0x0000000000581d55 in command_loop_1 () at ../../src/keyboard.c:1368 > (More stack frames follow...) > (gdb) p w > $16 = (struct window *) 0x47d22f0 > (gdb) p sw > $17 = (struct window *) 0x47d22f0 > (gdb) p XWINDOW(selected_window) > $18 = (struct window *) 0x61109d0 > (gdb) p w->contents > $19 = XIL(0) > (gdb) p XWINDOW(selected_window)->contents > $20 = XIL(0x493e565) > (gdb) xpr > Lisp_Vectorlike > PVEC_BUFFER > $21 = (struct buffer *) 0x493e560 > (unsigned char *) 0x4a34568 " *NeoTree*" I'm probably too silly to understand this. IIUC we are here /* do_pending_window_change could change the selected_window due to frame resizing which makes the selected window too small. */ if (WINDOWP (selected_window) && (w = XWINDOW (selected_window)) != sw) sw = w; /* Clear frames marked as garbaged. */ clear_garbaged_frames (); /* Build menubar and tool-bar items. */ if (NILP (Vmemory_full)) prepare_menu_bars (); reconsider_clip_changes (w); and the only ways this could cause w != XWINDOW(selected_window) before the last call is either !WINDOWP (selected_window) or that clear_garbaged_frames or prepare_menu_bars change selected_window. Can you find the responsible? martin From debbugs-submit-bounces@debbugs.gnu.org Wed May 02 07:53:17 2018 Received: (at submit) by debbugs.gnu.org; 2 May 2018 11:53:17 +0000 Received: from localhost ([127.0.0.1]:46418 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fDqJx-0006q4-6i for submit@debbugs.gnu.org; Wed, 02 May 2018 07:53:17 -0400 Received: from eggs.gnu.org ([208.118.235.92]:57758) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fDqJu-0006pq-OU for submit@debbugs.gnu.org; Wed, 02 May 2018 07:53:15 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fDqJo-0004g1-J4 for submit@debbugs.gnu.org; Wed, 02 May 2018 07:53:09 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50 autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:50515) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1fDqJo-0004fv-FG for submit@debbugs.gnu.org; Wed, 02 May 2018 07:53:08 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:48713) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fDqJn-0004Wc-2J for bug-gnu-emacs@gnu.org; Wed, 02 May 2018 07:53:08 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fDqJi-0004eR-86 for bug-gnu-emacs@gnu.org; Wed, 02 May 2018 07:53:07 -0400 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:45925) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fDqJi-0004eK-3R; Wed, 02 May 2018 07:53:02 -0400 Received: from [109.253.190.64] (port=43456 helo=[10.128.97.191]) by fencepost.gnu.org with esmtpsa (TLS1.2:DHE_RSA_AES_128_CBC_SHA1:128) (Exim 4.82) (envelope-from ) id 1fDqJh-0008MS-4u; Wed, 02 May 2018 07:53:01 -0400 Date: Wed, 02 May 2018 14:52:55 +0300 User-Agent: K-9 Mail for Android In-Reply-To: <5AE957BA.6000809@gmx.at> References: <87r2mvo6c8.fsf@gmail.com> <5AE87AA3.6050602@gmx.at> <87o9hznfam.fsf@gmail.com> <5AE957BA.6000809@gmx.at> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Subject: Re: bug#31312: Segmentation fault with doom-emacs, NeoTree and Zoom To: bug-gnu-emacs@gnu.org, martin rudalics , Noam Postavsky From: Eli Zaretskii Message-ID: X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 2001:4830:134:3::11 X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: submit Cc: 31312@debbugs.gnu.org, Andrea Cardaci X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -6.0 (------) On May 2, 2018 9:16:26 AM GMT+03:00, martin rudalics wr= ote: > >> Is w in reconsider_clip_changes the same as XWINDOW > (selected_window) > >> when it fails? > > > > Nope=2E In fact, doing > > > > break 13939 if (w !=3D XWINDOW(selected_window)) > > > > triggers only just before the bad reconsider_clip_changes call=2E > > > > #0 redisplay_internal () at =2E=2E/=2E=2E/src/xdisp=2Ec:13939 > > #1 0x0000000000463c16 in redisplay () at =2E=2E/=2E=2E/src/xdisp=2Ec= :13518 > > #2 0x00000000005851ae in read_char (commandflag=3D1, > map=3DXIL(0x5e99db3), prev_event=3DXIL(0), > > used_mouse_menu=3D0x7fffffffe41f, end_time=3D0x0) at > =2E=2E/=2E=2E/src/keyboard=2Ec:2480 > > #3 0x00000000005957c5 in read_key_sequence (keybuf=3D0x7fffffffe570, > bufsize=3D30, prompt=3DXIL(0), > > dont_downcase_last=3Dfalse, can_return_switch_frame=3Dtrue, > fix_current_buffer=3Dtrue, > > prevent_redisplay=3Dfalse) at =2E=2E/=2E=2E/src/keyboard=2Ec:914= 7 > > #4 0x0000000000581d55 in command_loop_1 () at > =2E=2E/=2E=2E/src/keyboard=2Ec:1368 > > (More stack frames follow=2E=2E=2E) > > (gdb) p w > > $16 =3D (struct window *) 0x47d22f0 > > (gdb) p sw > > $17 =3D (struct window *) 0x47d22f0 > > (gdb) p XWINDOW(selected_window) > > $18 =3D (struct window *) 0x61109d0 > > (gdb) p w->contents > > $19 =3D XIL(0) > > (gdb) p XWINDOW(selected_window)->contents > > $20 =3D XIL(0x493e565) > > (gdb) xpr > > Lisp_Vectorlike > > PVEC_BUFFER > > $21 =3D (struct buffer *) 0x493e560 > > (unsigned char *) 0x4a34568 " *NeoTree*" >=20 > I'm probably too silly to understand this=2E IIUC we are here >=20 > /* do_pending_window_change could change the selected_window due to > frame resizing which makes the selected window too small=2E */ > if (WINDOWP (selected_window) && (w =3D XWINDOW (selected_window)) !=3D > sw) > sw =3D w; >=20 > /* Clear frames marked as garbaged=2E */ > clear_garbaged_frames (); >=20 > /* Build menubar and tool-bar items=2E */ > if (NILP (Vmemory_full)) > prepare_menu_bars (); >=20 > reconsider_clip_changes (w); >=20 > and the only ways this could cause w !=3D XWINDOW(selected_window) > before the last call is either !WINDOWP (selected_window) or that > clear_garbaged_frames or prepare_menu_bars change selected_window=2E > Can you find the responsible? >=20 > martin Those are exactly the questions I'd like to have answers for=2E Btw, I tried to run the recipe in "emacs -Q", and it didn't crash, so I gu= ess something in doom-land is a necessary piece of this puzzle=2E Also, please take a look at zoom=2Eel: it hooks window-size-change-functio= ns and resizes the windows in that hook(!)=2E And prepare_menu_bars runs window-size-change-functions, which resets the frame's window-configuration-changed flag, assuming that no one in their right mind will change the configuration from a hook that notifies about changes in configuration=2E After all this madness, it's small wonder that we end up with a dead window in W=2E Of course, we need to protect us against such calamities in any case=2E=2E= =2E From debbugs-submit-bounces@debbugs.gnu.org Wed May 02 08:21:26 2018 Received: (at 31312) by debbugs.gnu.org; 2 May 2018 12:21:26 +0000 Received: from localhost ([127.0.0.1]:46453 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fDqlB-0007Uq-QT for submit@debbugs.gnu.org; Wed, 02 May 2018 08:21:26 -0400 Received: from mail-it0-f53.google.com ([209.85.214.53]:36499) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fDql9-0007Uc-66 for 31312@debbugs.gnu.org; Wed, 02 May 2018 08:21:23 -0400 Received: by mail-it0-f53.google.com with SMTP id e20-v6so16740779itc.1 for <31312@debbugs.gnu.org>; Wed, 02 May 2018 05:21:23 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=Qq5fDre7Jilu4rhUaH8fXvAMZ4XSUDGdC6CEYzaFPc8=; b=PiSXVpkFIHfNa6ApVzmMiJosYqYDKzOpW/nilk6lrrP6x926wHA3uNYoK4o9ylmLLu Q+hTUFgyjOEvvkP8tZT1bqbb1nPdXfBqNEClI8/6OvT8meE/3TiRpo5RYch0JZ1o55cZ 8bQvvuzdwFmYaiCx6xI8TS4Je9DXJdWeYXbfv8BU294TpLCkoedbEI4VKULA0fKQHXwe OJ14j96hVw8iPyh3m/czrcYtJOtp5iqnOD+XiGs7DAWga+GJdcpGW2qyvs9Gz4PZeTXe 4Rn7mMUeXlvkukQfIh6D9Z29JQdP/7D3PDELEBkD7GLttv8ayp7NiTQx+fsUMHTbXv8L i3AQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=Qq5fDre7Jilu4rhUaH8fXvAMZ4XSUDGdC6CEYzaFPc8=; b=rECETsk+y6iMt/oQNbmvI8cCwTBrj6ftTqzb/0IS/kF6LDxMkPsP3yM/uZ8m6akxxX v7UCsPidxYBoH5fr17IadwldrWtpFWyU7O3MVpDfZXT0+bFlE/FnoFkc+sgxNatprvUH 8V99C18En9zA9gqB/4ZFRHecRwPsJxLiSKjTX8MSMUMllh6kqs3Xsuamd5ToQTkBTzdW j0T+MEMQCRg8KFDuDJvYMYbVIitbbqeLtglFT0R4hM0ThwAsvudn84GQ3cd4gT1nd5r9 M9vLXkHn7wXDu1aIOCBGAnKX2qObT+MvpnUY2GSMM8JsViuWq1e1VBQKoUs1mYh4Jm12 r0DQ== X-Gm-Message-State: ALQs6tACm/5rW5EaKwZOV844LNDsA5Cyf8MnxRYnCU2pAReRlQQ+YiN5 j7CdXtJPGsb6ej1kEtQY0uo= X-Google-Smtp-Source: AB8JxZpXpvgBFLF4ouF0fnSL3pQqp0MJgY6ururCxB8cTPMpHM+MsqFUPIvFG+jJ5nLW71yDu58+jw== X-Received: by 2002:a24:3989:: with SMTP id l131-v6mr20215380ita.28.1525263677634; Wed, 02 May 2018 05:21:17 -0700 (PDT) Received: from zebian (cbl-45-2-119-34.yyz.frontiernetworks.ca. [45.2.119.34]) by smtp.googlemail.com with ESMTPSA id e15-v6sm5593805ioc.54.2018.05.02.05.21.16 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 02 May 2018 05:21:16 -0700 (PDT) From: Noam Postavsky To: martin rudalics Subject: Re: bug#31312: Segmentation fault with doom-emacs, NeoTree and Zoom References: <87r2mvo6c8.fsf@gmail.com> <5AE87AA3.6050602@gmx.at> <87o9hznfam.fsf@gmail.com> <5AE957BA.6000809@gmx.at> Date: Wed, 02 May 2018 08:21:15 -0400 In-Reply-To: <5AE957BA.6000809@gmx.at> (martin rudalics's message of "Wed, 02 May 2018 08:16:26 +0200") Message-ID: <87fu3ant8k.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1 (gnu/linux) MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 31312 Cc: 31312@debbugs.gnu.org, Andrea Cardaci X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) --=-=-= Content-Type: text/plain martin rudalics writes: > and the only ways this could cause w != XWINDOW(selected_window) > before the last call is either !WINDOWP (selected_window) or that > clear_garbaged_frames or prepare_menu_bars change selected_window. > Can you find the responsible? Yes, found it, seems to be a combination of zoom window-size-change-functions called via prepare_menu_bars and doom advice on balance-windows. I got 12 changes of selected_window. First hit summarized inline, the rest of the backtraces are attached below. #0 select_window_1 (window=XIL(0x1601c35), inhibit_point_swap=false) at ../../src/window.c:562 #1 0x00000000004aff15 in select_window (window=XIL(0x1601c35), norecord=XIL(0xc090), inhibit_point_swap=false) at ../../src/window.c:520 #2 0x00000000004b0183 in Fselect_window (window=XIL(0x1601c35), norecord=XIL(0xc090)) at ../../src/window.c:590 #3 0x00000000004beaa7 in Fdelete_window_internal (window=XIL(0x1696c35)) at ../../src/window.c:4667 #79 0x0000000000441b1a in safe_call1 (fn=XIL(0x4a9e6d0), arg=XIL(0x1600c35)) at ../../src/xdisp.c:2644 #80 0x00000000004bb27a in run_window_size_change_functions (frame=XIL(0x1600c35)) at ../../src/window.c:3457 #81 0x0000000000460409 in prepare_menu_bars () at ../../src/xdisp.c:12065 #82 0x0000000000465141 in redisplay_internal () at ../../src/xdisp.c:13937 #83 0x0000000000463c16 in redisplay () at ../../src/xdisp.c:13518 Lisp Backtrace: [...] "delete-window" (0xffff9ab0) [...] "doom/popup-close" (0xffffa068) [...] "doom*popups-save" (0xffffaa00) [...] "ad-Advice-balance-windows" (0xffffb530) "apply" (0xffffb528) "balance-windows" (0xffffb960) "let" (0xffffbcc0) "zoom--update" (0xffffbe10) [...] "zoom--handler" (0xffffc928) "redisplay_internal (C function)" (0x0) (defun zoom--on () [...] (add-hook 'window-size-change-functions #'zoom--handler) (defun zoom--handler (&optional window-or-frame norecord) [...] (with-selected-window [...] (zoom--update)))) (defun zoom--update () "Update the window layout in the current frame." (let (;; temporarily disables this mode during resize to avoid infinite ;; recursion (probably not needed thanks to the following) (zoom-mode nil) ;; temporarily disable all (even external) hooks about window ;; configuration changes to try to avoid potential flickering since ;; `balance-windows' calls them (window-configuration-change-hook nil) ;; make sure that other windows are resized nicely after resizing the ;; selected one (window-combination-resize t) ;; make sure that the exact same amount of pixels is assigned to all the ;; siblings (window-resize-pixelwise t)) ;; start from a balanced layout anyway (balance-windows) ;; check if the selected window is not ignored (unless (zoom--window-ignored-p) (zoom--resize) (zoom--fix-scroll)))) ;; doom/core/core-popups.el: (advice-add #'balance-windows :around #'doom*popups-save) (defun doom*popups-save (orig-fn &rest args) "Sets aside all popups before executing the original function, usually to prevent the popup(s) from messing up the UI (or vice versa)." (save-popups! (apply orig-fn args))) (defmacro save-popups! (&rest body) "Sets aside all popups before executing the original function, usually to prevent the popup(s) from messing up the UI (or vice versa)." `(let ((in-popup-p (doom-popup-p)) (popups (doom-popup-windows)) (doom-popup-remember-history t) (doom-popup-inhibit-autokill t)) (when popups (mapc #'doom/popup-close popups)) (unwind-protect (progn ,@body) (when popups (let ((origin (selected-window))) (doom/popup-restore) (unless in-popup-p (select-window origin))))))) --=-=-= Content-Type: text/plain Content-Disposition: attachment; filename=bug-31312.gdbinit.diff Content-Description: gdbinit modifications to catch bug diff --git i/src/.gdbinit w/src/.gdbinit index cc06b2e11c..0ebf07f0f7 100644 --- i/src/.gdbinit +++ w/src/.gdbinit @@ -1264,6 +1264,35 @@ commands end +watch selected_window +set $selwindow_watch = $bpnum +commands $selwindow_watch + bt +end +disable $selwindow_watch + +# this one never happens, I think +break xdisp.c:13929 if !WINDOWP(selected_window) + +break xdisp.c:13929 if WINDOWP(selected_window) +commands + silent + enable $selwindow_watch + continue +end +set $enable_selwindow_watch = $bpnum +disable $enable_selwindow_watch +printf "selected window watch enabler = %d\n", $enable_selwindow_watch + +break xdisp.c:13939 if !NILP(w->contents) +commands + silent + disable $selwindow_watch + continue +end + +break xdisp.c:13939 if NILP(w->contents) + # Put the Python code at the end of .gdbinit so that if GDB does not # support Python, GDB will do all the above initializations before # reporting an error. --=-=-= Content-Type: application/gzip Content-Disposition: attachment; filename=selwindow.log.gz Content-Transfer-Encoding: base64 Content-Description: gdb backtraces of the selected_window changes H4sIAISl6VoAA+2da3PjxpWGP0e/gjWzH2ayloP7JfG4auM4ta7yOqk42eQbCwTAGZUlUaYk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7ULEz/Pj2D1f/4e84Bm+v/g9DCslfR70CAA== --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Wed May 02 08:45:52 2018 Received: (at submit) by debbugs.gnu.org; 2 May 2018 12:45:52 +0000 Received: from localhost ([127.0.0.1]:46459 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fDr8p-00082Z-VB for submit@debbugs.gnu.org; Wed, 02 May 2018 08:45:52 -0400 Received: from eggs.gnu.org ([208.118.235.92]:42747) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fDr8o-00082N-NH for submit@debbugs.gnu.org; Wed, 02 May 2018 08:45:50 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fDr8i-00025i-80 for submit@debbugs.gnu.org; Wed, 02 May 2018 08:45:45 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50 autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:56165) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1fDr8i-00025X-50 for submit@debbugs.gnu.org; Wed, 02 May 2018 08:45:44 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:33689) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fDr8g-0006GK-K1 for bug-gnu-emacs@gnu.org; Wed, 02 May 2018 08:45:43 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fDr8b-000227-NR for bug-gnu-emacs@gnu.org; Wed, 02 May 2018 08:45:42 -0400 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:46898) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fDr8b-000223-JZ; Wed, 02 May 2018 08:45:37 -0400 Received: from [109.253.190.64] (port=43460 helo=[10.128.97.191]) by fencepost.gnu.org with esmtpsa (TLS1.2:DHE_RSA_AES_128_CBC_SHA1:128) (Exim 4.82) (envelope-from ) id 1fDr8a-0002Ci-Rp; Wed, 02 May 2018 08:45:37 -0400 Date: Wed, 02 May 2018 15:45:31 +0300 User-Agent: K-9 Mail for Android In-Reply-To: <87fu3ant8k.fsf@gmail.com> References: <87r2mvo6c8.fsf@gmail.com> <5AE87AA3.6050602@gmx.at> <87o9hznfam.fsf@gmail.com> <5AE957BA.6000809@gmx.at> <87fu3ant8k.fsf@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Subject: Re: bug#31312: Segmentation fault with doom-emacs, NeoTree and Zoom To: bug-gnu-emacs@gnu.org, Noam Postavsky , martin rudalics From: Eli Zaretskii Message-ID: <0DFE6C67-38C5-45EE-B658-8BEF80B595FF@gnu.org> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 2001:4830:134:3::11 X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: submit Cc: 31312@debbugs.gnu.org, Andrea Cardaci X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -6.0 (------) On May 2, 2018 3:21:15 PM GMT+03:00, Noam Postavsky = wrote: > martin rudalics writes: >=20 > > and the only ways this could cause w !=3D XWINDOW(selected_window) > > before the last call is either !WINDOWP (selected_window) or that > > clear_garbaged_frames or prepare_menu_bars change selected_window=2E > > Can you find the responsible? >=20 > Yes, found it, seems to be a combination of zoom > window-size-change-functions called via prepare_menu_bars and doom > advice on balance-windows=2E I got 12 changes of selected_window=2E=20 > First > hit summarized inline, the rest of the backtraces are attached below=2E >=20 > #0 select_window_1 (window=3DXIL(0x1601c35), inhibit_point_swap=3Dfalse= ) > at =2E=2E/=2E=2E/src/window=2Ec:562 > #1 0x00000000004aff15 in select_window (window=3DXIL(0x1601c35), > norecord=3DXIL(0xc090), inhibit_point_swap=3Dfalse) at > =2E=2E/=2E=2E/src/window=2Ec:520 > #2 0x00000000004b0183 in Fselect_window (window=3DXIL(0x1601c35), > norecord=3DXIL(0xc090)) at =2E=2E/=2E=2E/src/window=2Ec:590 > #3 0x00000000004beaa7 in Fdelete_window_internal > (window=3DXIL(0x1696c35)) at =2E=2E/=2E=2E/src/window=2Ec:4667 >=20 > #79 0x0000000000441b1a in safe_call1 (fn=3DXIL(0x4a9e6d0), > arg=3DXIL(0x1600c35)) at =2E=2E/=2E=2E/src/xdisp=2Ec:2644 > #80 0x00000000004bb27a in run_window_size_change_functions > (frame=3DXIL(0x1600c35)) at =2E=2E/=2E=2E/src/window=2Ec:3457 > #81 0x0000000000460409 in prepare_menu_bars () at > =2E=2E/=2E=2E/src/xdisp=2Ec:12065 > #82 0x0000000000465141 in redisplay_internal () at > =2E=2E/=2E=2E/src/xdisp=2Ec:13937 > #83 0x0000000000463c16 in redisplay () at =2E=2E/=2E=2E/src/xdisp=2Ec:13= 518 >=20 > Lisp Backtrace: > [=2E=2E=2E] > "delete-window" (0xffff9ab0) > [=2E=2E=2E] > "doom/popup-close" (0xffffa068) > [=2E=2E=2E] > "doom*popups-save" (0xffffaa00) > [=2E=2E=2E] > "ad-Advice-balance-windows" (0xffffb530) > "apply" (0xffffb528) > "balance-windows" (0xffffb960) > "let" (0xffffbcc0) > "zoom--update" (0xffffbe10) > [=2E=2E=2E] > "zoom--handler" (0xffffc928) > "redisplay_internal (C function)" (0x0) >=20 > (defun zoom--on () > [=2E=2E=2E] > (add-hook 'window-size-change-functions #'zoom--handler) >=20 > (defun zoom--handler (&optional window-or-frame norecord) > [=2E=2E=2E] > (with-selected-window > [=2E=2E=2E] > (zoom--update)))) >=20 > (defun zoom--update () > "Update the window layout in the current frame=2E" > (let (;; temporarily disables this mode during resize to avoid > infinite > ;; recursion (probably not needed thanks to the following) > (zoom-mode nil) > ;; temporarily disable all (even external) hooks about window > ;; configuration changes to try to avoid potential flickering since > ;; `balance-windows' calls them > (window-configuration-change-hook nil) > ;; make sure that other windows are resized nicely after resizing the > ;; selected one > (window-combination-resize t) > ;; make sure that the exact same amount of pixels is assigned to all > the > ;; siblings > (window-resize-pixelwise t)) > ;; start from a balanced layout anyway > (balance-windows) > ;; check if the selected window is not ignored > (unless (zoom--window-ignored-p) > (zoom--resize) > (zoom--fix-scroll)))) >=20 > ;; doom/core/core-popups=2Eel: > (advice-add #'balance-windows :around #'doom*popups-save) >=20 > (defun doom*popups-save (orig-fn &rest args) > "Sets aside all popups before executing the original function, usually > to > prevent the popup(s) from messing up the UI (or vice versa)=2E" > (save-popups! (apply orig-fn args))) >=20 > (defmacro save-popups! (&rest body) > "Sets aside all popups before executing the original function, usually > to > prevent the popup(s) from messing up the UI (or vice versa)=2E" > `(let ((in-popup-p (doom-popup-p)) > (popups (doom-popup-windows)) > (doom-popup-remember-history t) > (doom-popup-inhibit-autokill t)) > (when popups > (mapc #'doom/popup-close popups)) > (unwind-protect > (progn ,@body) > (when popups > (let ((origin (selected-window))) > (doom/popup-restore) > (unless in-popup-p > (select-window origin))))))) So we need the same defense after prepare_menu_bars as we have after do_pending_changes, I think=2E From debbugs-submit-bounces@debbugs.gnu.org Wed May 02 09:27:36 2018 Received: (at submit) by debbugs.gnu.org; 2 May 2018 13:27:37 +0000 Received: from localhost ([127.0.0.1]:46476 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fDrnE-0000iu-8J for submit@debbugs.gnu.org; Wed, 02 May 2018 09:27:36 -0400 Received: from eggs.gnu.org ([208.118.235.92]:50851) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fDrnD-0000ii-4N for submit@debbugs.gnu.org; Wed, 02 May 2018 09:27:35 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fDrn5-0006rn-Rg for submit@debbugs.gnu.org; Wed, 02 May 2018 09:27:29 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50,FREEMAIL_FROM, HTML_MESSAGE,T_DKIM_INVALID autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:48346) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1fDrn5-0006rf-NI for submit@debbugs.gnu.org; Wed, 02 May 2018 09:27:27 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:41775) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fDrn0-0001Bj-T6 for bug-gnu-emacs@gnu.org; Wed, 02 May 2018 09:27:27 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fDrmz-0006oH-72 for bug-gnu-emacs@gnu.org; Wed, 02 May 2018 09:27:22 -0400 Received: from mail-qk0-x230.google.com ([2607:f8b0:400d:c09::230]:41288) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1fDrmr-0006g9-R5; Wed, 02 May 2018 09:27:13 -0400 Received: by mail-qk0-x230.google.com with SMTP id d125so11172506qkb.8; Wed, 02 May 2018 06:27:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=QzEPqZjR09eo8MJcr1y7f8hkB2yxcW9W7pn7U9VCEQA=; b=QhfnwCI6QVEGlIOen1IXWftOh884JgpuuWv+dTcUucVYiydhUmMeo3GkqVxTDLB7kQ eGtZrj3crtiHVGqLRpvstQd6VTiWI3YAt6A/koAWwBMl3kEXf5zHR1WUQmFnOUIPzp3D /5ZAsYTLfwPoOLCg0cngetywgbexSxs2thI0uUbmj5n0RnMXqW7ufewRjhqR68xncCf0 DrEDNZcE1Hl2wFQwRA8FJ105PaQeqjYHkaD6hnnUuw4quCyYdnWJ+ms7quvJxVBmvx3J +6Sak59gn+xktam/rsR53CG6dj64JlIDq4leAU2E106TYOpJmX13JSdw1pAUm6zk7OjS tJig== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=QzEPqZjR09eo8MJcr1y7f8hkB2yxcW9W7pn7U9VCEQA=; b=HiORC1vaaPz1kkmoZ8FcXR5X+cuqgPzz3uUyiZWcNc0hOGrhnpSmUAxMhDEM2ki2cD 5jq9FcesvTU7Tz7pqFUEizKhLv5pTlS77cyj3wtNFApBxXPr19sWgYa9HF8V68jLCjN0 cgGdrDgJ9+/KaXiBBbz/BOJPtF1kqHnFESolSIMZryjGSsIUEB51RWM8O/62y1hUlue6 BXStePtmZGl6hFKc4abfIVrALcizY/V+L6oAF696aTapdINovFx7LjE1q1HQ8F1ZaL01 OQ4r7Bz9IrFJ6jn6mVRsDUBKSWfEcWyMpPWROgypdaL455XZxLQzIEy7FgJBRQRaefJK Mz/g== X-Gm-Message-State: ALQs6tDnWB03M7D7XvA5rWtUWwJNF4McKL4gA5zg+K9st/eTJ/LT0tuy lEfGmtl40EIe+MI0NUJyKQtF5BeCXZ0g+9bJoiOXH5Uc X-Google-Smtp-Source: AB8JxZrGyB5w3t3ofq2ynEidgWW9nryt8gLFKNpGDw1R/D8Nrp1NLusObDcRVOz2dmbooBR8B/KpK8K5FK/Xb+pixNg= X-Received: by 10.55.203.193 with SMTP id u62mr14431990qkl.83.1525267632577; Wed, 02 May 2018 06:27:12 -0700 (PDT) MIME-Version: 1.0 Received: by 10.200.63.210 with HTTP; Wed, 2 May 2018 06:27:12 -0700 (PDT) In-Reply-To: <0DFE6C67-38C5-45EE-B658-8BEF80B595FF@gnu.org> References: <87r2mvo6c8.fsf@gmail.com> <5AE87AA3.6050602@gmx.at> <87o9hznfam.fsf@gmail.com> <5AE957BA.6000809@gmx.at> <87fu3ant8k.fsf@gmail.com> <0DFE6C67-38C5-45EE-B658-8BEF80B595FF@gnu.org> From: Andrea Cardaci Date: Wed, 2 May 2018 15:27:12 +0200 Message-ID: Subject: Re: bug#31312: Segmentation fault with doom-emacs, NeoTree and Zoom To: Eli Zaretskii Content-Type: multipart/alternative; boundary="001a1134e2ba6d6371056b390b60" X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 2001:4830:134:3::11 X-Spam-Score: -4.0 (----) X-Debbugs-Envelope-To: submit Cc: martin rudalics , bug-gnu-emacs@gnu.org, Noam Postavsky , 31312@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -5.0 (-----) --001a1134e2ba6d6371056b390b60 Content-Type: text/plain; charset="UTF-8" > Also, please take a look at zoom.el: it hooks window-size-change-functions > and resizes the windows in that hook(!). > assuming that no one in their right > mind will change the configuration from a hook that notifies about > changes in configuration Yeah, I'm that guy... Any advice on this part? I needed to force the size of windows and hooking `select-window` (via `advice-add`) is apparently not enough to catch all the cases. Is there a better way to achieve what I want? On 2 May 2018 at 14:45, Eli Zaretskii wrote: > On May 2, 2018 3:21:15 PM GMT+03:00, Noam Postavsky > wrote: > > martin rudalics writes: > > > > > and the only ways this could cause w != XWINDOW(selected_window) > > > before the last call is either !WINDOWP (selected_window) or that > > > clear_garbaged_frames or prepare_menu_bars change selected_window. > > > Can you find the responsible? > > > > Yes, found it, seems to be a combination of zoom > > window-size-change-functions called via prepare_menu_bars and doom > > advice on balance-windows. I got 12 changes of selected_window. > > First > > hit summarized inline, the rest of the backtraces are attached below. > > > > #0 select_window_1 (window=XIL(0x1601c35), inhibit_point_swap=false) > > at ../../src/window.c:562 > > #1 0x00000000004aff15 in select_window (window=XIL(0x1601c35), > > norecord=XIL(0xc090), inhibit_point_swap=false) at > > ../../src/window.c:520 > > #2 0x00000000004b0183 in Fselect_window (window=XIL(0x1601c35), > > norecord=XIL(0xc090)) at ../../src/window.c:590 > > #3 0x00000000004beaa7 in Fdelete_window_internal > > (window=XIL(0x1696c35)) at ../../src/window.c:4667 > > > > #79 0x0000000000441b1a in safe_call1 (fn=XIL(0x4a9e6d0), > > arg=XIL(0x1600c35)) at ../../src/xdisp.c:2644 > > #80 0x00000000004bb27a in run_window_size_change_functions > > (frame=XIL(0x1600c35)) at ../../src/window.c:3457 > > #81 0x0000000000460409 in prepare_menu_bars () at > > ../../src/xdisp.c:12065 > > #82 0x0000000000465141 in redisplay_internal () at > > ../../src/xdisp.c:13937 > > #83 0x0000000000463c16 in redisplay () at ../../src/xdisp.c:13518 > > > > Lisp Backtrace: > > [...] > > "delete-window" (0xffff9ab0) > > [...] > > "doom/popup-close" (0xffffa068) > > [...] > > "doom*popups-save" (0xffffaa00) > > [...] > > "ad-Advice-balance-windows" (0xffffb530) > > "apply" (0xffffb528) > > "balance-windows" (0xffffb960) > > "let" (0xffffbcc0) > > "zoom--update" (0xffffbe10) > > [...] > > "zoom--handler" (0xffffc928) > > "redisplay_internal (C function)" (0x0) > > > > (defun zoom--on () > > [...] > > (add-hook 'window-size-change-functions #'zoom--handler) > > > > (defun zoom--handler (&optional window-or-frame norecord) > > [...] > > (with-selected-window > > [...] > > (zoom--update)))) > > > > (defun zoom--update () > > "Update the window layout in the current frame." > > (let (;; temporarily disables this mode during resize to avoid > > infinite > > ;; recursion (probably not needed thanks to the following) > > (zoom-mode nil) > > ;; temporarily disable all (even external) hooks about window > > ;; configuration changes to try to avoid potential flickering since > > ;; `balance-windows' calls them > > (window-configuration-change-hook nil) > > ;; make sure that other windows are resized nicely after resizing the > > ;; selected one > > (window-combination-resize t) > > ;; make sure that the exact same amount of pixels is assigned to all > > the > > ;; siblings > > (window-resize-pixelwise t)) > > ;; start from a balanced layout anyway > > (balance-windows) > > ;; check if the selected window is not ignored > > (unless (zoom--window-ignored-p) > > (zoom--resize) > > (zoom--fix-scroll)))) > > > > ;; doom/core/core-popups.el: > > (advice-add #'balance-windows :around #'doom*popups-save) > > > > (defun doom*popups-save (orig-fn &rest args) > > "Sets aside all popups before executing the original function, usually > > to > > prevent the popup(s) from messing up the UI (or vice versa)." > > (save-popups! (apply orig-fn args))) > > > > (defmacro save-popups! (&rest body) > > "Sets aside all popups before executing the original function, usually > > to > > prevent the popup(s) from messing up the UI (or vice versa)." > > `(let ((in-popup-p (doom-popup-p)) > > (popups (doom-popup-windows)) > > (doom-popup-remember-history t) > > (doom-popup-inhibit-autokill t)) > > (when popups > > (mapc #'doom/popup-close popups)) > > (unwind-protect > > (progn ,@body) > > (when popups > > (let ((origin (selected-window))) > > (doom/popup-restore) > > (unless in-popup-p > > (select-window origin))))))) > > So we need the same defense after prepare_menu_bars as we > have after do_pending_changes, I think. > --001a1134e2ba6d6371056b390b60 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
> Also, please take a look at zoom.el: it hooks wi= ndow-size-change-functions
> and resizes the windows in th= at hook(!).

> assuming that no one in their rig= ht
> mind will change the configuration from a hook that notif= ies about
> changes in configuration

= Yeah, I'm that guy...

Any advice on this part?= I needed to force the size of windows and hooking `select-window`=C2=A0(via `advice-add`) is apparently= not enough to catch all the cases.

Is there a bet= ter way to achieve what I want?

<= div class=3D"gmail_quote">On 2 May 2018 at 14:45, Eli Zaretskii <eliz@gnu.org= > wrote:
On May 2, 2018 3:21:15 PM GMT+03:00, Noam Postavsky &= lt;npostavs@gmail.com> wrote:<= br> > martin rudalics <rudalics@gmx.at= > writes:
>
> > and the only ways this could cause w !=3D XWINDOW(selected_window= )
> > before the last call is either !WINDOWP (selected_window) or that=
> > clear_garbaged_frames or prepare_menu_bars change selected_window= .
> > Can you find the responsible?
>
> Yes, found it, seems to be a combination of zoom
> window-size-change-functions called via prepare_menu_bars and doom
> advice on balance-windows.=C2=A0 I got 12 changes of selected_window. =
> First
> hit summarized inline, the rest of the backtraces are attached below.<= br> >
> #0=C2=A0 select_window_1 (window=3DXIL(0x1601c35), inhibit_point_swap= =3Dfalse)
> at ../../src/window.c:562
> #1=C2=A0 0x00000000004aff15 in select_window (window=3DXIL(0x1601c35),=
> norecord=3DXIL(0xc090), inhibit_point_swap=3Dfalse) at
> ../../src/window.c:520
> #2=C2=A0 0x00000000004b0183 in Fselect_window (window=3DXIL(0x1601c35)= ,
> norecord=3DXIL(0xc090)) at ../../src/window.c:590
> #3=C2=A0 0x00000000004beaa7 in Fdelete_window_internal
> (window=3DXIL(0x1696c35)) at ../../src/window.c:4667
>
> #79 0x0000000000441b1a in safe_call1 (fn=3DXIL(0x4a9e6d0),
> arg=3DXIL(0x1600c35)) at ../../src/xdisp.c:2644
> #80 0x00000000004bb27a in run_window_size_change_functions
> (frame=3DXIL(0x1600c35)) at ../../src/window.c:3457
> #81 0x0000000000460409 in prepare_menu_bars () at
> ../../src/xdisp.c:12065
> #82 0x0000000000465141 in redisplay_internal () at
> ../../src/xdisp.c:13937
> #83 0x0000000000463c16 in redisplay () at ../../src/xdisp.c:13518
>
> Lisp Backtrace:
> [...]
> "delete-window" (0xffff9ab0)
> [...]
> "doom/popup-close" (0xffffa068)
> [...]
> "doom*popups-save" (0xffffaa00)
> [...]
> "ad-Advice-balance-windows" (0xffffb530)
> "apply" (0xffffb528)
> "balance-windows" (0xffffb960)
> "let" (0xffffbcc0)
> "zoom--update" (0xffffbe10)
> [...]
> "zoom--handler" (0xffffc928)
> "redisplay_internal (C function)" (0x0)
>
> (defun zoom--on ()
>=C2=A0 =C2=A0[...]
>=C2=A0 =C2=A0(add-hook 'window-size-change-functions #'zoom--ha= ndler)
>
> (defun zoom--handler (&optional window-or-frame norecord)
>=C2=A0 =C2=A0[...]
>=C2=A0 =C2=A0 =C2=A0(with-selected-window
>=C2=A0 =C2=A0 =C2=A0 =C2=A0[...]
>=C2=A0 =C2=A0 =C2=A0 =C2=A0(zoom--update))))
>
> (defun zoom--update ()
>=C2=A0 =C2=A0"Update the window layout in the current frame."=
> (let (;; temporarily disables this mode during resize to avoid
> infinite
>=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0;; recursion (probably not needed tha= nks to the following)
>=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0(zoom-mode nil)
>=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0;; temporarily disable all (even exte= rnal) hooks about window
>=C2=A0 =C2=A0 ;; configuration changes to try to avoid potential flicke= ring since
>=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0;; `balance-windows' calls them >=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0(window-configuration-change-hoo= k nil)
>=C2=A0 ;; make sure that other windows are resized nicely after resizin= g the
>=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0;; selected one
>=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0(window-combination-resize t)
> ;; make sure that the exact same amount of pixels is assigned to all > the
>=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0;; siblings
>=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0(window-resize-pixelwise t))
>=C2=A0 =C2=A0 =C2=A0;; start from a balanced layout anyway
>=C2=A0 =C2=A0 =C2=A0(balance-windows)
>=C2=A0 =C2=A0 =C2=A0;; check if the selected window is not ignored
>=C2=A0 =C2=A0 =C2=A0(unless (zoom--window-ignored-p)
>=C2=A0 =C2=A0 =C2=A0 =C2=A0(zoom--resize)
>=C2=A0 =C2=A0 =C2=A0 =C2=A0(zoom--fix-scroll))))
>
> ;; doom/core/core-popups.el:
>=C2=A0 =C2=A0(advice-add #'balance-windows :around #'doom*popup= s-save)
>
> (defun doom*popups-save (orig-fn &rest args)
> "Sets aside all popups before executing the original function, us= ually
> to
> prevent the popup(s) from messing up the UI (or vice versa)."
>=C2=A0 =C2=A0(save-popups! (apply orig-fn args)))
>
> (defmacro save-popups! (&rest body)
> "Sets aside all popups before executing the original function, us= ually
> to
> prevent the popup(s) from messing up the UI (or vice versa)."
>=C2=A0 =C2=A0`(let ((in-popup-p (doom-popup-p))
>=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (popups (doom-popup-windows))
>=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (doom-popup-remember-history t)
>=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (doom-popup-inhibit-autokill t))
>=C2=A0 =C2=A0 =C2=A0 (when popups
>=C2=A0 =C2=A0 =C2=A0 =C2=A0 (mapc #'doom/popup-close popups))
>=C2=A0 =C2=A0 =C2=A0 (unwind-protect
>=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (progn ,@body)
>=C2=A0 =C2=A0 =C2=A0 =C2=A0 (when popups
>=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (let ((origin (selected-window))) >=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (doom/popup-restore)
>=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (unless in-popup-p
>=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (select-window origin)= ))))))

So we need the same defense after prepare_menu_bars as we
have after do_pending_changes, I think.

--001a1134e2ba6d6371056b390b60-- From debbugs-submit-bounces@debbugs.gnu.org Wed May 02 09:42:47 2018 Received: (at 31312) by debbugs.gnu.org; 2 May 2018 13:42:47 +0000 Received: from localhost ([127.0.0.1]:46491 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fDs1v-00016x-0r for submit@debbugs.gnu.org; Wed, 02 May 2018 09:42:47 -0400 Received: from mout.gmx.net ([212.227.15.15]:60817) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fDs1t-00016g-QK for 31312@debbugs.gnu.org; Wed, 02 May 2018 09:42:46 -0400 Received: from [192.168.1.101] ([213.162.73.252]) by mail.gmx.com (mrgmx001 [212.227.17.190]) with ESMTPSA (Nemesis) id 0MYfX0-1esPHB0MCo-00VTwI; Wed, 02 May 2018 15:42:39 +0200 Message-ID: <5AE9C045.7080300@gmx.at> Date: Wed, 02 May 2018 15:42:29 +0200 From: martin rudalics MIME-Version: 1.0 To: Noam Postavsky Subject: Re: bug#31312: Segmentation fault with doom-emacs, NeoTree and Zoom References: <87r2mvo6c8.fsf@gmail.com> <5AE87AA3.6050602@gmx.at> <87o9hznfam.fsf@gmail.com> <5AE957BA.6000809@gmx.at> <87fu3ant8k.fsf@gmail.com> In-Reply-To: <87fu3ant8k.fsf@gmail.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Provags-ID: V03:K1:ftpACn9lHFX46aUqr1tgs1j1ZhjcLThVTHaJX2OoK+bDbBQG5jP ZYV8kt0gvyEU4NU+3CVMKAZufCP6DmLOLOv3Iu6PUJNZwmjUG033DHKv/ZW3sg76RUzJFeM 1JZLady0NQyvu295ebvvShlbT6GMhg0rqrb2QWU56d1ajPTxterMKfqiAKJM1Q2gB9A1Ad/ WArW3idtW5sP9wT7ntSrg== X-UI-Out-Filterresults: notjunk:1;V01:K0:8qjHcjBnP/g=:PhADp9a2MPno/Q89BgCmTE 8g2e9iRkqMJDmvew7sgeayqgNkbWXNEvPuq8oCRWtF7VbQ9o9iyec9uyzwoSGTgztdwG7byDl iTyicpnCxFfJF0TnO1WMJFyeJDdj9IFvkq94lrqAw91Wc/0e73kOYcDC+qdHEU0A8NaTtpwme COXenXZ/qLj3jGfQ1VtQuQfVOsDXpqKZwdjHDHqXJrbN/YFpyHITUKZ7EBe4DaJYNi0tmYt8E LYNClta4AS5dv+iuHYrUxW9AuzR2S96KhMaY5E9uSrkTR0Ps6lSw56UaDQBTRQi139H44J+lA vy3Yh/4zozapQ5gAOOtFMoj29GEb2Lopl6aIedwhIKzVYUEtCbReR6e2mMy990I6JI04RbhP5 TA43spNjhtdgD9HQ4gSus9HfpYvn0wICKGU5D1Pn1dwMT44nYDwxPnPPMQIIZDk0BYISITwa/ b7cW2PmvTnHUzCm7a9+z/Y3qtUYUMlSqOr1Yc2fXiImpKkD4TE6Zw/GKIWq34wmgFu1hSwivm og/Z8j3EHGJuyTIPbTX1SIGtmJcrwlAyPiT+4lEYqD11jiU7/zMYSsv/KDAdrDKakRcDuu8S/ gnj0nTc+GMW15yVrg0lIL5TdFSbDYbdaONQl11P66mC7anh/dekCAYWpaIBIIuDqPDdAHv0L5 0vacPd8/tkNFhwZvttPn69ReN/Qz2BR+ojMN7T49PNA26zLcRhvirSqww50RGGVxKXAq5wKnD kk5csQun+J+ciD1GCV3GYFKoDMKZfPRuNMK44meevq4EEWVBYc8kE3/COZusVmIA1eUeXSSDq qQBboe2 X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 31312 Cc: 31312@debbugs.gnu.org, Andrea Cardaci X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) > Yes, found it, seems to be a combination of zoom > window-size-change-functions called via prepare_menu_bars and doom > advice on balance-windows. I got 12 changes of selected_window. First > hit summarized inline, the rest of the backtraces are attached below. Magnificent, many thanks. A first interpretation is as follows (please correct me if you think I'm wrong): The first hit stems from a call of 'delete-window' where 'frame-first-window' apparently finds a bad window. The remainders but the last one come from running 'window-configuration-change-hook' where the saved selected window after running the local part of the hook is dead. The last one comes from 'window-size-change-functions' where a call of 'select-window' apparently succeeds passing us a bad window. The 'window-configuration-change-hook' instances are design failures - we simply have to let the selected window alone when the saved one has been deleted. The other two deserve some investigation. martin From debbugs-submit-bounces@debbugs.gnu.org Wed May 02 09:43:30 2018 Received: (at submit) by debbugs.gnu.org; 2 May 2018 13:43:31 +0000 Received: from localhost ([127.0.0.1]:46498 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fDs2c-00018f-MV for submit@debbugs.gnu.org; Wed, 02 May 2018 09:43:30 -0400 Received: from eggs.gnu.org ([208.118.235.92]:55067) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fDs2a-00018S-Ln for submit@debbugs.gnu.org; Wed, 02 May 2018 09:43:28 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fDs2S-0005mK-Am for submit@debbugs.gnu.org; Wed, 02 May 2018 09:43:23 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=BAYES_20,FREEMAIL_FROM autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:43212) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1fDs2S-0005mG-7v for submit@debbugs.gnu.org; Wed, 02 May 2018 09:43:20 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:46014) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fDs2R-0008Rn-0T for bug-gnu-emacs@gnu.org; Wed, 02 May 2018 09:43:19 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fDs2N-0005jt-Ux for bug-gnu-emacs@gnu.org; Wed, 02 May 2018 09:43:19 -0400 Received: from mout.gmx.net ([212.227.15.19]:45295) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1fDs2N-0005h2-JV; Wed, 02 May 2018 09:43:15 -0400 Received: from [192.168.1.101] ([213.162.73.252]) by mail.gmx.com (mrgmx001 [212.227.17.190]) with ESMTPSA (Nemesis) id 0M7Xi3-1eSfRF1uCN-00xKgb; Wed, 02 May 2018 15:43:06 +0200 Message-ID: <5AE9C062.9010203@gmx.at> Date: Wed, 02 May 2018 15:42:58 +0200 From: martin rudalics MIME-Version: 1.0 To: Eli Zaretskii , bug-gnu-emacs@gnu.org, Noam Postavsky Subject: Re: bug#31312: Segmentation fault with doom-emacs, NeoTree and Zoom References: <87r2mvo6c8.fsf@gmail.com> <5AE87AA3.6050602@gmx.at> <87o9hznfam.fsf@gmail.com> <5AE957BA.6000809@gmx.at> <87fu3ant8k.fsf@gmail.com> <0DFE6C67-38C5-45EE-B658-8BEF80B595FF@gnu.org> In-Reply-To: <0DFE6C67-38C5-45EE-B658-8BEF80B595FF@gnu.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Provags-ID: V03:K1:8ZIRYFNqNAMpztDle6vnn8UsXIjB86RAAmB8G8EqCRg9h4uXJGT KFiGOnvcL/GVy+LLacOZwhTsIDx0qRZkaWNcAA2t8DeDW2h4Qm8+pKubgWllaI3MiHGxSDY p7eoIsfhYqFX0cFHoDd6SmUCiZNhTLNn4+vMhtUvSj/RbhxejXaHYxurfOEaL9NhAEaT8wZ uQZKWC2DPrzdmfAf4Ao/g== X-UI-Out-Filterresults: notjunk:1;V01:K0:V1al7rp4YQI=:50GWex0hw8tOPN3ya26TcI Dex7weGWsz4mVD7wnr6GZ3T1q/QSEn7WApbSZu1HJnkB7YnVruAiPDltlV8ub0lSCSF+ED5Km cohPPQhRBeBudxHOTT2J0hWPyeXZu0G80q6iEv+awSPp0lsv2Ft80MXo8Dfvo7ZOeOU8WmOSu DTOJPvjz4sOwNnJMViGwBdkfszkWQhZ46XHKH4yx8D5Zoy5nlLP7ttUVI6MLkM0xRZR4hSwt5 tx8yjMrjOYPSmT1QYoQ0e8UBh1xlbpNNPUbAWopVQkGtLb9S9ziH7G3qXPmG21WCa1J0/Ww4A nSvwmDi/samgj2QBFseydKL+JklFp4hy56OetCspI+qdKY9WN2nw2VH3u6LScx56dieOIbQmE TDla7Yq3m9/i82iKLFhbV6gB4VCOrwce3ccdUpWhhOrZunMSLsXmDlkCVTcM1M4gtTvR0keRb iR2VDfG4ByWDf//nEUNa/fGtusYxRgkVK5rv/Ohb7IPvaJhgPGWHX11WF03inqemj9mWsJouf L669iok5/1OXMkxAJ7pxOLMynNzsyGOYnMTQtgPrWuBbq4mQcvvgolUkkb4doptH1KDyBB2FB 2Laqm8ZX+tl3r1qt7xbOxj9XiTcy9C5g27ME8vzU3DRK7hukpm7Vs05SNCkG8IHnZnCG4CFDX rR40RLHqV8cCFw/3z9uO9+VIrV0qJUdW2NFnDqw897qW+q5FJ2b0N3QHSkN5OMi8Wj2m3Mt8c niY/hvaabIFHqoFwqqAFsjDxaWABfCLd3Xhp5h5JgneYE7Fqd4UOArka6ZfNFP8Gtc2yHiK5r UoqxN5a X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 2001:4830:134:3::11 X-Spam-Score: -4.1 (----) X-Debbugs-Envelope-To: submit Cc: 31312@debbugs.gnu.org, Andrea Cardaci X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -5.1 (-----) > So we need the same defense after prepare_menu_bars as we > have after do_pending_changes, I think. If you mean something like if (WINDOWP (selected_window) && (w = XWINDOW (selected_window)) != sw) sw = w; I'm afraid that this would fail since selected_window has no buffer any more (or may have even been recycled already). Or am I missing something? martin From debbugs-submit-bounces@debbugs.gnu.org Wed May 02 09:47:48 2018 Received: (at 31312) by debbugs.gnu.org; 2 May 2018 13:47:48 +0000 Received: from localhost ([127.0.0.1]:46506 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fDs6m-0001HK-GJ for submit@debbugs.gnu.org; Wed, 02 May 2018 09:47:48 -0400 Received: from mout.gmx.net ([212.227.15.18]:40681) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fDs6k-0001H7-EQ for 31312@debbugs.gnu.org; Wed, 02 May 2018 09:47:47 -0400 Received: from [192.168.1.101] ([213.162.73.252]) by mail.gmx.com (mrgmx001 [212.227.17.190]) with ESMTPSA (Nemesis) id 0Lmb2Z-1eeoTA3Fgp-00aBFT; Wed, 02 May 2018 15:47:39 +0200 Message-ID: <5AE9C174.8030104@gmx.at> Date: Wed, 02 May 2018 15:47:32 +0200 From: martin rudalics MIME-Version: 1.0 To: Andrea Cardaci , Eli Zaretskii Subject: Re: bug#31312: Segmentation fault with doom-emacs, NeoTree and Zoom References: <87r2mvo6c8.fsf@gmail.com> <5AE87AA3.6050602@gmx.at> <87o9hznfam.fsf@gmail.com> <5AE957BA.6000809@gmx.at> <87fu3ant8k.fsf@gmail.com> <0DFE6C67-38C5-45EE-B658-8BEF80B595FF@gnu.org> In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Provags-ID: V03:K1:6D72eonQ1tU+HRkHBjlOetOhoBY/DeBAnyRNAdQgWkdLB+2HzZZ mlDXy4Bl9Rp43fnU1A5yus1OkbGU4/LYnCwaT3g86JQ34iIhlG9Af1huD2gfpntk9kRrdIR g6voQHHEpv3csw2X/AXAQ+mBN8Qznd/SznbokscCh6V025Ir35Qk1JQuHABTWvHeq7kZJNs VmH0D8kx+QMOCi03xGaJA== X-UI-Out-Filterresults: notjunk:1;V01:K0:glvG/1X7Iuc=:HCkhL9pfqNib+89D4sg+/U FKtovl1sKhzzcpi5JiXVP692CIv9ylrmT3C/idDoLVfINBk+OrlS5rFc5GuWq+DInbJshlbwx XZOPr19bR+hvmRKYsndCF/1DKaomS/SSGwmtGrqteIlN8TsCynxjL1+pg97KhWWvfqOoHXvAU Svgf5vIpYmFTAyXRCTB4Fg/+KhFXydDgGQP1vMXAjtTqEihbjHqhzwQkxJpidD2Pz0iz3eS+Q 23YwhXioVVqrgiBO+Z6beMU5Kc0nVSNN+hlcqq3q/pufVpFW/xlsLbj1yy9nKDBZVjA0eiruF e+kv25g6VsV58ZI7tqb1Kz8kMVyEzDEQpFgXQXWseTnXxx2MEVk/ffwWZ27Taw1zO9gMR/8pk nVQ2iEqEuRAeLRhIQkEm38gFQ5T2E+JduB/AkmSI66nIjCwz8KmyVnShP089QHmvs8QkCcbWI Jolnz8mgqPzSKC41gZ1/JJuro1cfvTf2LNPwK423ymtAjeDx/0RDDR6CnUJGMPPRsaJPtpEbg ZI27n/SKonQs5q8I9QdTqCyBix7PQiPGB/h4v+syRX5i5dyP1BP01GlKTTnA9LjvLCZwE2kkT f3jSAWrqY2UfR3U6t9ylN2ktSTXSXxQraMcy+2KPgW9xxWchzgCwcGJfhl2yvZkenT1f55DYe QrXklIndX5EyRf+iNq3wmUYEvKKBxltaDnADTE3BP3N+bvrtl8u0nor8bGbQ7N7MuB6mlGhwM /cBtZjcAKzXiGxs82P74+o7h+SDq+2Ha5xj9cnmgL7Abr3NK2NDdJuEaAZZJkWR9Ug2UYBQ59 Rh5s2xb X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 31312 Cc: bug-gnu-emacs@gnu.org, Noam Postavsky , 31312@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) > Any advice on this part? I needed to force the size of windows and hooking > `select-window` (via `advice-add`) is apparently not enough to catch all > the cases. It might not help in the case at hand, but instead of advising 'select-window' (which won't do the job anyway when a window is selected directly via select_window) please add your function to 'buffer-list-update-hook'. Hooking 'select-window' _is_ bad idea, always. martin From debbugs-submit-bounces@debbugs.gnu.org Wed May 02 11:04:07 2018 Received: (at 31312) by debbugs.gnu.org; 2 May 2018 15:04:07 +0000 Received: from localhost ([127.0.0.1]:47167 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fDtId-0003C6-IR for submit@debbugs.gnu.org; Wed, 02 May 2018 11:04:07 -0400 Received: from eggs.gnu.org ([208.118.235.92]:45414) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fDtIb-0003Bb-AG for 31312@debbugs.gnu.org; Wed, 02 May 2018 11:04:05 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fDtIV-0001ZC-72 for 31312@debbugs.gnu.org; Wed, 02 May 2018 11:04:00 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50 autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:48774) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fDtIQ-0001Xt-NF; Wed, 02 May 2018 11:03:54 -0400 Received: from [176.228.60.248] (port=4605 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1fDtIP-0005OH-Pd; Wed, 02 May 2018 11:03:54 -0400 Date: Wed, 02 May 2018 18:03:45 +0300 Message-Id: <831seuqeum.fsf@gnu.org> From: Eli Zaretskii To: martin rudalics In-reply-to: <5AE9C062.9010203@gmx.at> (message from martin rudalics on Wed, 02 May 2018 15:42:58 +0200) Subject: Re: bug#31312: Segmentation fault with doom-emacs, NeoTree and Zoom References: <87r2mvo6c8.fsf@gmail.com> <5AE87AA3.6050602@gmx.at> <87o9hznfam.fsf@gmail.com> <5AE957BA.6000809@gmx.at> <87fu3ant8k.fsf@gmail.com> <0DFE6C67-38C5-45EE-B658-8BEF80B595FF@gnu.org> <5AE9C062.9010203@gmx.at> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: 31312 Cc: cyrus.and@gmail.com, npostavs@gmail.com, 31312@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Eli Zaretskii Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -6.0 (------) > Date: Wed, 02 May 2018 15:42:58 +0200 > From: martin rudalics > CC: 31312@debbugs.gnu.org, Andrea Cardaci > > > So we need the same defense after prepare_menu_bars as we > > have after do_pending_changes, I think. > > If you mean something like > > if (WINDOWP (selected_window) && (w = XWINDOW (selected_window)) != sw) > sw = w; > > I'm afraid that this would fail since selected_window has no buffer > any more (or may have even been recycled already). Is that a fact? I might be mistaken, but my take on what Noam found was that the selected window is OK, it's just that the window held in W is dead (i.e. it was deleted inside the tempest that happened in run_window_size_change_functions called by prepare_menu_bars). So my suggestion is to update W with the new selected window. In general, if the selected window has no buffer, we are in deep trouble, and not just in redisplay. So I very much hope this is not what happens here. From debbugs-submit-bounces@debbugs.gnu.org Wed May 02 11:06:34 2018 Received: (at submit) by debbugs.gnu.org; 2 May 2018 15:06:34 +0000 Received: from localhost ([127.0.0.1]:47179 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fDtL0-0003GF-II for submit@debbugs.gnu.org; Wed, 02 May 2018 11:06:34 -0400 Received: from eggs.gnu.org ([208.118.235.92]:46230) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fDtKz-0003G2-DA for submit@debbugs.gnu.org; Wed, 02 May 2018 11:06:33 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fDtKq-0002gr-BN for submit@debbugs.gnu.org; Wed, 02 May 2018 11:06:28 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50,FREEMAIL_FROM, HTML_MESSAGE,T_DKIM_INVALID autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:36813) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1fDtKq-0002gl-84 for submit@debbugs.gnu.org; Wed, 02 May 2018 11:06:24 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:37160) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fDtKo-0006oE-St for bug-gnu-emacs@gnu.org; Wed, 02 May 2018 11:06:24 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fDtKj-0002dn-4w for bug-gnu-emacs@gnu.org; Wed, 02 May 2018 11:06:22 -0400 Received: from mail-qk0-x233.google.com ([2607:f8b0:400d:c09::233]:32791) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1fDtKe-0002ae-Pk; Wed, 02 May 2018 11:06:12 -0400 Received: by mail-qk0-x233.google.com with SMTP id c70so11466865qkg.0; Wed, 02 May 2018 08:06:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=8tDqRa3RG6gaIv55Nr4jJk5JJjwy31OaAwSp7/zXtvM=; b=NVWdX2Qc0qE5t2G+wto2zFUKh/R6ajmWD5PsNb8xqFpvFZu4j/Jnx4kRJD6XpCNPX6 dybXBLH7k10tibt1QFcY0HEpfiaS1MgJCrjgVHUV3zRNvSjF4iD+0O52xGaj2reeG+KO 41aI0ClqEmf8pBrf8CwRQwhIhNJr+M6Dgh7yRFCdQ1DqGuVo6ydbql+pRfJEF4xWjDXR A2z6DkEm8BPsR0R5sMvx+/GEkOFa8p4ZlyrgPfEZ343pe/8rQTyDiSzJMUgYuwdLPDsu b28nJazM7Igui2h3kxP5I0uswIYjmuwhS78QC/NGZiOkgbw73zIoJj4IzYD06Beu3rRj ruEw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=8tDqRa3RG6gaIv55Nr4jJk5JJjwy31OaAwSp7/zXtvM=; b=VdOAK24iE6hCQJyrOi/liL5p7siJMC8/3I3aqXNSChit7qmyzWdal6GXdlAm8WwE1D eWhk8bEhqgbU7WZ+9pkf8JrIEq94+RY9D8CDwLUCcnHiKYND/1PtU17vwGSxloOcCEe1 7xTz+zX3MC1xM+C+OqK6SL/qE64S0x1kL0jCJinS/ITwFHQ7Qn3gsz2QdZd+FFIoDL1v xArZlxtgupB2baQywvE1cPDoI0raUiqSUdzoNCuO37vWU4IG9pmvxkozTNflOny8gxcR ZvGqp8+F6gEAXYdymeaB46OkH+8dXk56SjU+6nTMbAK/iGulhfxYSj3cJmtPHN24HWF7 X7FA== X-Gm-Message-State: ALQs6tBFwHHmjk4Hjl/rEyeg/szebRUYDtXZFLeidrBV9O3nhrjNx9MO QsoK+mpI8kabpOAblhI+CjUPcAvCiz2QOHe/Iew= X-Google-Smtp-Source: AB8JxZp8ViRMdxy4UhaPbYbADiLB8ZTEyJ4fzOXR/S0XBE70rBxrLX6N5MJvXP/yCtmgzCnv98dzAQxySSv26+ow8oU= X-Received: by 10.55.124.198 with SMTP id x189mr16183698qkc.224.1525273571996; Wed, 02 May 2018 08:06:11 -0700 (PDT) MIME-Version: 1.0 Received: by 10.200.63.210 with HTTP; Wed, 2 May 2018 08:06:11 -0700 (PDT) In-Reply-To: <5AE9C174.8030104@gmx.at> References: <87r2mvo6c8.fsf@gmail.com> <5AE87AA3.6050602@gmx.at> <87o9hznfam.fsf@gmail.com> <5AE957BA.6000809@gmx.at> <87fu3ant8k.fsf@gmail.com> <0DFE6C67-38C5-45EE-B658-8BEF80B595FF@gnu.org> <5AE9C174.8030104@gmx.at> From: Andrea Cardaci Date: Wed, 2 May 2018 17:06:11 +0200 Message-ID: Subject: Re: bug#31312: Segmentation fault with doom-emacs, NeoTree and Zoom To: martin rudalics Content-Type: multipart/alternative; boundary="94eb2c06262271b9a0056b3a6d04" X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 2001:4830:134:3::11 X-Spam-Score: -4.0 (----) X-Debbugs-Envelope-To: submit Cc: Eli Zaretskii , 31312@debbugs.gnu.org, bug-gnu-emacs@gnu.org, Noam Postavsky X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -5.0 (-----) --94eb2c06262271b9a0056b3a6d04 Content-Type: text/plain; charset="UTF-8" > It might not help in the case at hand, but instead of advising > 'select-window' (which won't do the job anyway when a window is > selected directly via select_window) please add your function to > 'buffer-list-update-hook'. Hooking 'select-window' _is_ bad idea, > always. I will try that, even though I'm pretty sure that I already tried this approach in the past and switched back to advising `select-window` but I cannot recall the reason. On 2 May 2018 at 15:47, martin rudalics wrote: > > Any advice on this part? I needed to force the size of windows and > hooking > > `select-window` (via `advice-add`) is apparently not enough to catch all > > the cases. > > It might not help in the case at hand, but instead of advising > 'select-window' (which won't do the job anyway when a window is > selected directly via select_window) please add your function to > 'buffer-list-update-hook'. Hooking 'select-window' _is_ bad idea, > always. > > martin > --94eb2c06262271b9a0056b3a6d04 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
> It might not help in the case at hand, but inste= ad of advising
> 'select-window' (which won't do t= he job anyway when a window is
> selected directly via select_= window) please add your function to
> 'buffer-list-update-= hook'.=C2=A0 Hooking 'select-window' _is_ bad idea,
&= gt; always.

I will try that, even though I'm p= retty sure that I already tried this approach in the past and switched back= to advising `select-window` but I cannot recall the reason.

On 2 May 2018 at 15:= 47, martin rudalics <rudalics@gmx.at> wrote:
> Any advice on this part? I needed to= force the size of windows and hooking
> `select-window` (via `advice-add`) is apparently not enough to catch a= ll
> the cases.

It might not help in the case at hand, but instead of advising
'select-window' (which won't do the job anyway when a window is=
selected directly via select_window) please add your function to
'buffer-list-update-hook'.=C2=A0 Hooking 'select-window' _i= s_ bad idea,
always.

martin

--94eb2c06262271b9a0056b3a6d04-- From debbugs-submit-bounces@debbugs.gnu.org Wed May 02 11:07:02 2018 Received: (at 31312) by debbugs.gnu.org; 2 May 2018 15:07:02 +0000 Received: from localhost ([127.0.0.1]:47182 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fDtLR-0003Gv-SA for submit@debbugs.gnu.org; Wed, 02 May 2018 11:07:02 -0400 Received: from eggs.gnu.org ([208.118.235.92]:46441) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fDtLQ-0003Gi-LB for 31312@debbugs.gnu.org; Wed, 02 May 2018 11:07:00 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fDtLK-0002sq-OS for 31312@debbugs.gnu.org; Wed, 02 May 2018 11:06:55 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50 autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:48826) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fDtLK-0002sm-LL; Wed, 02 May 2018 11:06:54 -0400 Received: from [176.228.60.248] (port=4615 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1fDtLK-0002xg-4Q; Wed, 02 May 2018 11:06:54 -0400 Date: Wed, 02 May 2018 18:06:47 +0300 Message-Id: <83zi1ip054.fsf@gnu.org> From: Eli Zaretskii To: Andrea Cardaci In-reply-to: (message from Andrea Cardaci on Wed, 2 May 2018 15:27:12 +0200) Subject: Re: bug#31312: Segmentation fault with doom-emacs, NeoTree and Zoom References: <87r2mvo6c8.fsf@gmail.com> <5AE87AA3.6050602@gmx.at> <87o9hznfam.fsf@gmail.com> <5AE957BA.6000809@gmx.at> <87fu3ant8k.fsf@gmail.com> <0DFE6C67-38C5-45EE-B658-8BEF80B595FF@gnu.org> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: 31312 Cc: rudalics@gmx.at, npostavs@gmail.com, 31312@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Eli Zaretskii Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -6.0 (------) > From: Andrea Cardaci > Date: Wed, 2 May 2018 15:27:12 +0200 > Cc: bug-gnu-emacs@gnu.org, Noam Postavsky , > martin rudalics , 31312@debbugs.gnu.org > > Any advice on this part? I needed to force the size of windows and hooking `select-window` (via `advice-add`) > is apparently not enough to catch all the cases. > > Is there a better way to achieve what I want? If what Martin suggested somehow doesn't fit the bill, and no other ideas are brought up, then I prefer to discuss new features or infrastructure to satisfy similar needs, rather than force applications to use such fragile techniques. E.g., we could provide some customizable controls in the code that resizes windows when needed. From debbugs-submit-bounces@debbugs.gnu.org Wed May 02 11:14:13 2018 Received: (at 31312) by debbugs.gnu.org; 2 May 2018 15:14:14 +0000 Received: from localhost ([127.0.0.1]:47188 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fDtSP-0003RQ-Lp for submit@debbugs.gnu.org; Wed, 02 May 2018 11:14:13 -0400 Received: from mail-qt0-f177.google.com ([209.85.216.177]:38329) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fDtSM-0003RB-J6 for 31312@debbugs.gnu.org; Wed, 02 May 2018 11:14:11 -0400 Received: by mail-qt0-f177.google.com with SMTP id z23-v6so18840630qti.5 for <31312@debbugs.gnu.org>; Wed, 02 May 2018 08:14:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=WRDNkFug7xCx+JqLbgJ/n9ti1/Wyk9RNdhOEMyIKvlY=; b=O7pZzLO/z+XYVKtp/aQTVrGgnflhSoOVF8v2aRG9xaKRsyYLYkAigKNnnM1DAzNXzS bij+fxhNd06JgRTFWUjVuqHfdrdC9KZ4fcBiVxDgWf9BHArWJbS5lST1PJLRsyxRMaO4 BfOgTrHXRZJ3v1ypYWpuuQcjEN2bB4u6Fa4fGH0lLASz6cSu3bnHHnRj75cORneWozOb DOF9epr5ydlh98KHTLS83HX4rbZQepTrG7pL43RB32JtILiZxMHaZjNhv7uZRQCHjfcs rHRhQ5LrXqeWXPD+oH/Hhjz/JPtp3U9xXVXbhOae2Nt/sSBCdXcDvcJbHg7iuLRI6Qp7 MC+Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=WRDNkFug7xCx+JqLbgJ/n9ti1/Wyk9RNdhOEMyIKvlY=; b=HPUITaq9sIOqpXELzXXi6cYLu6KoJaTIFu+IV2G29/Gkgvu5vMDhLv0Z7i1cEXyX7S jU4hB4cymE+f9yvuozgE67Gip3lzkIDGMwC+mioH3T8JaYaeeUVE9Tpe2cIUPvdMcnTb 1iLEl8rWMcNGog/FQ8oH6VuK9o1wtrskX7RjWa4lomnv7xZc/wUBJQV4r/b9hQgBxnW/ mLXry/rX93jeW8YJcSQkEgKuLdUJ2+qNfqX3bbFurddQBzfSywDAbRbV7O56hQeojZt9 XI3C+cQQuRzdQnuJqDeJhX3AhBSuyf6RqY7rX7C2f2exKHOgPHXFm3rc/9njqLH8HHa3 3SNg== X-Gm-Message-State: ALQs6tBUFFpZdaXU7A/Eoa8Jipypn2I6xA2B7dU+dFW1G+z88ATWi//L bAnCWXQITgnVEA3zOComXX2w/R8zG8nzLJqX1BA= X-Google-Smtp-Source: AB8JxZpZC/ASqnHGbfC25Gt2dlSpLMA6+nwVkWRifhf4iw1O6UV42bJUkLtW0wM1Y1ysnsI1u2c3vwP/LjI6nlZXi3A= X-Received: by 2002:ac8:3f72:: with SMTP id w47-v6mr16841511qtk.318.1525274044921; Wed, 02 May 2018 08:14:04 -0700 (PDT) MIME-Version: 1.0 Received: by 10.200.63.210 with HTTP; Wed, 2 May 2018 08:14:04 -0700 (PDT) In-Reply-To: <83zi1ip054.fsf@gnu.org> References: <87r2mvo6c8.fsf@gmail.com> <5AE87AA3.6050602@gmx.at> <87o9hznfam.fsf@gmail.com> <5AE957BA.6000809@gmx.at> <87fu3ant8k.fsf@gmail.com> <0DFE6C67-38C5-45EE-B658-8BEF80B595FF@gnu.org> <83zi1ip054.fsf@gnu.org> From: Andrea Cardaci Date: Wed, 2 May 2018 17:14:04 +0200 Message-ID: Subject: Re: bug#31312: Segmentation fault with doom-emacs, NeoTree and Zoom To: Eli Zaretskii Content-Type: multipart/alternative; boundary="000000000000a1fba7056b3a899e" X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 31312 Cc: martin rudalics , Noam Postavsky , 31312@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) --000000000000a1fba7056b3a899e Content-Type: text/plain; charset="UTF-8" > If what Martin suggested somehow doesn't fit the bill It doesn't, because it deals with advising `select-window` while the main issue here is that I resize windows in the `window-size-change-functions` hook (albeit using a guard to avoid infinite recursion) and I can't come up any workarounds for that. On 2 May 2018 at 17:06, Eli Zaretskii wrote: > > From: Andrea Cardaci > > Date: Wed, 2 May 2018 15:27:12 +0200 > > Cc: bug-gnu-emacs@gnu.org, Noam Postavsky , > > martin rudalics , 31312@debbugs.gnu.org > > > > Any advice on this part? I needed to force the size of windows and > hooking `select-window` (via `advice-add`) > > is apparently not enough to catch all the cases. > > > > Is there a better way to achieve what I want? > > If what Martin suggested somehow doesn't fit the bill, and no other > ideas are brought up, then I prefer to discuss new features or > infrastructure to satisfy similar needs, rather than force > applications to use such fragile techniques. E.g., we could provide > some customizable controls in the code that resizes windows when > needed. > --000000000000a1fba7056b3a899e Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
>=C2=A0If what Martin sugges= ted somehow doesn't fit the bill
=
It doesn't, because it= deals with advising `select-window` while the main issue here is that I re= size windows in the `window-size-change-functions` hook (albeit using a gua= rd to avoid infinite recursion) and I can't come up any workarounds for= that.

On 2 May 2018 at 17:06, Eli Zaretskii <eliz@gnu.org> wrot= e:
> From: Andrea Cardaci <cyrus.and@gmail.com>
> Date: Wed, 2 May 2018 15:27:12 +0200
> Cc: bug-gnu-emacs@gnu.org= , Noam Postavsky <npostavs@gmail.c= om>,
>=C2=A0 =C2=A0 =C2=A0 =C2=A0martin rudalics <rudalics@gmx.at>, 31312@debbugs.gnu.org
>
> Any advice on this part? I needed to force the size of windows and hoo= king `select-window` (via `advice-add`)
> is apparently not enough to catch all the cases.
>
> Is there a better way to achieve what I want?

If what Martin suggested somehow doesn't fit the bill, and no ot= her
ideas are brought up, then I prefer to discuss new features or
infrastructure to satisfy similar needs, rather than force
applications to use such fragile techniques.=C2=A0 E.g., we could provide some customizable controls in the code that resizes windows when
needed.

--000000000000a1fba7056b3a899e-- From debbugs-submit-bounces@debbugs.gnu.org Wed May 02 11:30:25 2018 Received: (at 31312) by debbugs.gnu.org; 2 May 2018 15:30:26 +0000 Received: from localhost ([127.0.0.1]:47203 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fDti5-0003re-N8 for submit@debbugs.gnu.org; Wed, 02 May 2018 11:30:25 -0400 Received: from eggs.gnu.org ([208.118.235.92]:52809) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fDti3-0003rN-Ge for 31312@debbugs.gnu.org; Wed, 02 May 2018 11:30:23 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fDths-00088u-Dp for 31312@debbugs.gnu.org; Wed, 02 May 2018 11:30:18 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50 autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:49191) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fDths-00088n-9U; Wed, 02 May 2018 11:30:12 -0400 Received: from [176.228.60.248] (port=4636 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1fDthr-0002ep-Oy; Wed, 02 May 2018 11:30:12 -0400 Date: Wed, 02 May 2018 18:30:04 +0300 Message-Id: <83sh7aoz2b.fsf@gnu.org> From: Eli Zaretskii To: Andrea Cardaci In-reply-to: (message from Andrea Cardaci on Wed, 2 May 2018 17:14:04 +0200) Subject: Re: bug#31312: Segmentation fault with doom-emacs, NeoTree and Zoom References: <87r2mvo6c8.fsf@gmail.com> <5AE87AA3.6050602@gmx.at> <87o9hznfam.fsf@gmail.com> <5AE957BA.6000809@gmx.at> <87fu3ant8k.fsf@gmail.com> <0DFE6C67-38C5-45EE-B658-8BEF80B595FF@gnu.org> <83zi1ip054.fsf@gnu.org> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: 31312 Cc: rudalics@gmx.at, npostavs@gmail.com, 31312@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Eli Zaretskii Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -6.0 (------) > From: Andrea Cardaci > Date: Wed, 2 May 2018 17:14:04 +0200 > Cc: Noam Postavsky , martin rudalics , 31312@debbugs.gnu.org > > > If what Martin suggested somehow doesn't fit the bill > > It doesn't, because it deals with advising `select-window` while the main issue here is that I resize windows in > the `window-size-change-functions` hook (albeit using a guard to avoid infinite recursion) and I can't come up > any workarounds for that. In that case, could you explain in more detail what zoom.el attempts to do, and what does it need from Emacs core to be able to do that? (It's probably better to start a new discussion on emacs-devel, not here.) Thanks. From debbugs-submit-bounces@debbugs.gnu.org Wed May 02 14:43:49 2018 Received: (at 31312) by debbugs.gnu.org; 2 May 2018 18:43:49 +0000 Received: from localhost ([127.0.0.1]:47314 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fDwjE-0008QK-4R for submit@debbugs.gnu.org; Wed, 02 May 2018 14:43:48 -0400 Received: from mout.gmx.net ([212.227.17.20]:51621) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fDwjC-0008Q7-FK for 31312@debbugs.gnu.org; Wed, 02 May 2018 14:43:46 -0400 Received: from [192.168.1.102] ([213.162.73.88]) by mail.gmx.com (mrgmx101 [212.227.17.168]) with ESMTPSA (Nemesis) id 0LkCU2-1ec8rg3Bta-00c7jl; Wed, 02 May 2018 20:43:38 +0200 Message-ID: <5AEA06D2.5010208@gmx.at> Date: Wed, 02 May 2018 20:43:30 +0200 From: martin rudalics MIME-Version: 1.0 To: Eli Zaretskii Subject: Re: bug#31312: Segmentation fault with doom-emacs, NeoTree and Zoom References: <87r2mvo6c8.fsf@gmail.com> <5AE87AA3.6050602@gmx.at> <87o9hznfam.fsf@gmail.com> <5AE957BA.6000809@gmx.at> <87fu3ant8k.fsf@gmail.com> <0DFE6C67-38C5-45EE-B658-8BEF80B595FF@gnu.org> <5AE9C062.9010203@gmx.at> <831seuqeum.fsf@gnu.org> In-Reply-To: <831seuqeum.fsf@gnu.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Provags-ID: V03:K1:q1c/kZpjcxMuBq5ygP2uGi4N26YHyzFcbfFrbAS5pHQx8lipVfw Bo8MGoXz/7aFzE6estvCDFyZF6C49GoEpBdGCtkLwA67c5N/E+/fb58l/bvPsdnntpf6+u1 e3LOUlzWhkP+CRwvLPjkJ9UBx8+nX5QNK/ZBbB+hhWCb2V6gk7tZiwZLlvsQOSaeU7jRdyu uAPHmVkETyyHMShzzPu+Q== X-UI-Out-Filterresults: notjunk:1;V01:K0:iAaMebwCq9o=:TG8SO4inRRUpwLfHdKgK4W x1ZvZbpoWTOVE3e1N3htWeT4w7txEgoOlWfH+W91tgodkUdTYqcuRNifhaw+EGn4Q8IqddYhn 1IwkV+otTdTUG0e+BVKB9LwRW+LIXdUmns4SW6ShSunV/d5DtYtoKDrJbU9tsS4VMiFxtKpRp GqBIjornuJtyWziJkv7dY8qxHU73kVC3jox31whfvj1n95JBHBlVE2VkNVkW89vv8iKR8LsWv zoB4iI90e7rPd6eJ8IRF/7h8BbD+PtH5DbRLA6VUhQ1Hc4HCH5aQ8b2mVmHa6M7cLb78wBBV/ ckwzidJ+vBDiZ+MTbtRCuyJXJzt92EZXTKCc5ilQ1+D9V5YYJf1ohm2x1T2lDfNHwWp6dMY1L ZImUDrruTBbHdkn5QSzFck3eV26impAXRg2m8UTL8h+4C0mvYOs1ZOq9FsB3rWWjZDROznk7t clVdOB2TvpTVTMFu3gR8y0hcTE/xUPIM/toVkH/qHj/8axNrat4F+oGDrjDn7ufcdpOmDliUc 8w36H1x3eYOVVDvf+mpHt+BrLdb7uhVxLNzcqwWfWYADM7CqW9Uk7Z7KT2FrofOeAzjuypxkR LNK2rY7yz/rumW2z4/Jm8SPtMAl3U+bAsiMZ4drFbh/XQKS/Ju/6lL77IYCt0dLTKAOpOo7BN X7YiwuPc7MiJXJYU5+z7efHLbtLl4RowfaJUtwu6NZbuMLV1UA7rhYtVam5i3LnX73IwilP6D 3ZYMbGrBlG9xN8SAhBaJs0yZyrPg6a3bHNE1Krrr0Bow1PXghlzmhy8X2u5NCVcsD8SSCIcm1 VJnftkI X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 31312 Cc: cyrus.and@gmail.com, npostavs@gmail.com, 31312@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) >> If you mean something like >> >> if (WINDOWP (selected_window) && (w = XWINDOW (selected_window)) != sw) >> sw = w; >> >> I'm afraid that this would fail since selected_window has no buffer >> any more (or may have even been recycled already). > > Is that a fact? I might be mistaken, but my take on what Noam found > was that the selected window is OK, it's just that the window held in > W is dead (i.e. it was deleted inside the tempest that happened in > run_window_size_change_functions called by prepare_menu_bars). So my > suggestion is to update W with the new selected window. Then I misinterpreted Noam's results. Anyway, a simple way to reproduce the bug is (defun foo (frame) (delete-window (selected-window))) (add-hook 'window-size-change-functions 'foo) and do C-x 2. martin From debbugs-submit-bounces@debbugs.gnu.org Wed May 02 15:02:55 2018 Received: (at 31312) by debbugs.gnu.org; 2 May 2018 19:02:55 +0000 Received: from localhost ([127.0.0.1]:47327 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fDx1j-0000QX-EP for submit@debbugs.gnu.org; Wed, 02 May 2018 15:02:55 -0400 Received: from eggs.gnu.org ([208.118.235.92]:53124) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fDx1i-0000QM-G2 for 31312@debbugs.gnu.org; Wed, 02 May 2018 15:02:54 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fDx1c-00065V-D1 for 31312@debbugs.gnu.org; Wed, 02 May 2018 15:02:49 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:52681) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fDx1Z-00063v-78; Wed, 02 May 2018 15:02:45 -0400 Received: from [176.228.60.248] (port=1210 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1fDx1X-0007J3-Rz; Wed, 02 May 2018 15:02:45 -0400 Date: Wed, 02 May 2018 22:02:32 +0300 Message-Id: <83k1slq3sn.fsf@gnu.org> From: Eli Zaretskii To: martin rudalics In-reply-to: <5AEA06D2.5010208@gmx.at> (message from martin rudalics on Wed, 02 May 2018 20:43:30 +0200) Subject: Re: bug#31312: Segmentation fault with doom-emacs, NeoTree and Zoom References: <87r2mvo6c8.fsf@gmail.com> <5AE87AA3.6050602@gmx.at> <87o9hznfam.fsf@gmail.com> <5AE957BA.6000809@gmx.at> <87fu3ant8k.fsf@gmail.com> <0DFE6C67-38C5-45EE-B658-8BEF80B595FF@gnu.org> <5AE9C062.9010203@gmx.at> <831seuqeum.fsf@gnu.org> <5AEA06D2.5010208@gmx.at> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: 31312 Cc: cyrus.and@gmail.com, npostavs@gmail.com, 31312@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Eli Zaretskii Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -6.0 (------) > Date: Wed, 02 May 2018 20:43:30 +0200 > From: martin rudalics > CC: npostavs@gmail.com, 31312@debbugs.gnu.org, cyrus.and@gmail.com > > (defun foo (frame) > (delete-window (selected-window))) > > (add-hook 'window-size-change-functions 'foo) > > and do C-x 2. Right, and as you can see, selected_window is still a valid leaf window when we abort in this case. From debbugs-submit-bounces@debbugs.gnu.org Wed May 02 20:04:38 2018 Received: (at 31312) by debbugs.gnu.org; 3 May 2018 00:04:38 +0000 Received: from localhost ([127.0.0.1]:47456 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fE1ji-0007P6-0n for submit@debbugs.gnu.org; Wed, 02 May 2018 20:04:38 -0400 Received: from mail-io0-f177.google.com ([209.85.223.177]:42592) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fE1jg-0007Ot-6f for 31312@debbugs.gnu.org; Wed, 02 May 2018 20:04:36 -0400 Received: by mail-io0-f177.google.com with SMTP id a10-v6so19596667ioc.9 for <31312@debbugs.gnu.org>; Wed, 02 May 2018 17:04:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=GhI8BSgOj6rxjdRGPgcCbRGIUWokq3r+AQOTBDbTZPk=; b=Yr0gQh2R3Aa1A5fXJiL2hD0XdkxeleoovJl2+YDukK5S/lB89J5KzG1U5Vmgn8qMYb cG5p4zdqVWq94O2cxMGOdpvMj2rDF1GEN4LcMiUUE4+g2ZpCOSAxqgOqbmHv7QIdA8wx u/GHn4tUDdkjWYQ9PXB0XYHeYPciy1YzdGLiSZdU8P9Wtw1tvunsvUXXv2H7qy7LbQk+ LzthoguJEJ3L4adFzZzXyThRFQfQtYW9WLvMi4b9gAFvbtwyUENEu4Kh5wwexdUNduHH d0rsc8B9aKOveLeGdnQv1lEnMF/FsQMn8Y1MblARd3300gIi9BMX9gvAI5IT8Skc1Ztf xxhw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=GhI8BSgOj6rxjdRGPgcCbRGIUWokq3r+AQOTBDbTZPk=; b=gdeZfM6/sbqSlj9KnrPwWjIMmzgkdVa0NjVrXE/RNXFfuSZJ6GLZvqHhb67N1+r+8o D/xNJXv+GFZNIJtM3N2+93UK+9boXfccjIjTfDdnAx0qzEkpryWtUL2eltICqABx1pAQ c7u1GgaSGgk7YTJoWs/5//DV/JdmP7MU6Eg1Mt+G4LbxTHmT2mJWJb/jpXxUbAVJTtCm BbfzvHfk8lkpqT4y0vGGnT5M/+QJI5d82Mwf94+sKzBKlFB/bLjQwIhAhYALC3/81h8a B87dUln+C0ZaLUK+gb1EMNQ9d+WE6TR88gMmrkW8wCFxeBfnxWCNjLw5pxph3ADDaUOz 54oA== X-Gm-Message-State: ALQs6tBIPg17wmBmNhMtb1BFA17pGGTO6AsOtHk10KhHxHrk3AzTlAOb ZZ3oteTtmMgiLx8W8WuVLuc= X-Google-Smtp-Source: AB8JxZougjWjdFKvtr+qu/PXSVEfvyrMIfrmJ9BEeUFki7+MWjKa4SHOC8PkIjvqqte353Q32eHLOg== X-Received: by 2002:a6b:86a7:: with SMTP id q39-v6mr23010066ioi.140.1525305870544; Wed, 02 May 2018 17:04:30 -0700 (PDT) Received: from zebian (cbl-45-2-119-34.yyz.frontiernetworks.ca. [45.2.119.34]) by smtp.googlemail.com with ESMTPSA id w133-v6sm296031itc.1.2018.05.02.17.04.29 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 02 May 2018 17:04:29 -0700 (PDT) From: Noam Postavsky To: martin rudalics Subject: Re: bug#31312: Segmentation fault with doom-emacs, NeoTree and Zoom References: <87r2mvo6c8.fsf@gmail.com> <5AE87AA3.6050602@gmx.at> <87o9hznfam.fsf@gmail.com> <5AE957BA.6000809@gmx.at> <87fu3ant8k.fsf@gmail.com> <0DFE6C67-38C5-45EE-B658-8BEF80B595FF@gnu.org> <5AE9C062.9010203@gmx.at> Date: Wed, 02 May 2018 20:04:28 -0400 In-Reply-To: <5AE9C062.9010203@gmx.at> (martin rudalics's message of "Wed, 02 May 2018 15:42:58 +0200") Message-ID: <87d0ydob8z.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 31312 Cc: eliz@gnu.org, 31312@debbugs.gnu.org, cyrus.and@gmail.com X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) martin rudalics writes: >> So we need the same defense after prepare_menu_bars as we >> have after do_pending_changes, I think. > > If you mean something like > > if (WINDOWP (selected_window) && (w = XWINDOW (selected_window)) != sw) > sw = w; > > I'm afraid that this would fail since selected_window has no buffer > any more (or may have even been recycled already). Or am I missing > something? It seems to work (I don't know enough about the code to explain why). I applied this patch: --- i/src/xdisp.c +++ w/src/xdisp.c @@ -13936,6 +13936,11 @@ redisplay_internal (void) if (NILP (Vmemory_full)) prepare_menu_bars (); + /* prepare_menu_bars may call lisp hooks and hence change the + selected_window. */ + if (WINDOWP (selected_window) && (w = XWINDOW (selected_window)) != sw) + sw = w; + reconsider_clip_changes (w); /* In most cases selected window displays current buffer. */ And then following the original recipe does not segfault. There is a Lisp error, but I think that's already a bug in zoom and/or doom. Debugger entered--Lisp error: (wrong-type-argument window-live-p #) set-window-dedicated-p(# t) neo-window--init(# #) neo-global--create-window() neo-global--get-window(t) neo-global--open-dir("/home/npostavs/src/doom/") neo-global--open() neotree-show() funcall-interactively(neotree-show) call-interactively(neotree-show record nil) command-execute(neotree-show record) #f(compiled-function (cmd) #)("neotree-show") ivy-call() ivy-read("M-x " ("toggle-debug-on-error" "zoom-mode" [...] counsel-M-x() funcall-interactively(counsel-M-x) call-interactively(counsel-M-x nil nil) command-execute(counsel-M-x) From debbugs-submit-bounces@debbugs.gnu.org Wed May 02 22:33:05 2018 Received: (at 31312) by debbugs.gnu.org; 3 May 2018 02:33:05 +0000 Received: from localhost ([127.0.0.1]:47559 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fE43N-0006Qa-9D for submit@debbugs.gnu.org; Wed, 02 May 2018 22:33:05 -0400 Received: from eggs.gnu.org ([208.118.235.92]:33813) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fE43K-0006Q3-UO for 31312@debbugs.gnu.org; Wed, 02 May 2018 22:33:03 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fE43E-0007On-Kd for 31312@debbugs.gnu.org; Wed, 02 May 2018 22:32:57 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-0.0 required=5.0 tests=BAYES_40 autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:58723) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fE438-0007MH-SD; Wed, 02 May 2018 22:32:50 -0400 Received: from [176.228.60.248] (port=1514 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1fE438-0006El-8o; Wed, 02 May 2018 22:32:50 -0400 Date: Thu, 03 May 2018 05:32:44 +0300 Message-Id: <83h8nppiyb.fsf@gnu.org> From: Eli Zaretskii To: Noam Postavsky In-reply-to: <87d0ydob8z.fsf@gmail.com> (message from Noam Postavsky on Wed, 02 May 2018 20:04:28 -0400) Subject: Re: bug#31312: Segmentation fault with doom-emacs, NeoTree and Zoom References: <87r2mvo6c8.fsf@gmail.com> <5AE87AA3.6050602@gmx.at> <87o9hznfam.fsf@gmail.com> <5AE957BA.6000809@gmx.at> <87fu3ant8k.fsf@gmail.com> <0DFE6C67-38C5-45EE-B658-8BEF80B595FF@gnu.org> <5AE9C062.9010203@gmx.at> <87d0ydob8z.fsf@gmail.com> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: 31312 Cc: rudalics@gmx.at, 31312@debbugs.gnu.org, cyrus.and@gmail.com X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Eli Zaretskii Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -6.0 (------) > From: Noam Postavsky > Cc: eliz@gnu.org, 31312@debbugs.gnu.org, cyrus.and@gmail.com > Date: Wed, 02 May 2018 20:04:28 -0400 > > martin rudalics writes: > > >> So we need the same defense after prepare_menu_bars as we > >> have after do_pending_changes, I think. > > > > If you mean something like > > > > if (WINDOWP (selected_window) && (w = XWINDOW (selected_window)) != sw) > > sw = w; > > > > I'm afraid that this would fail since selected_window has no buffer > > any more (or may have even been recycled already). Or am I missing > > something? > > It seems to work (I don't know enough about the code to explain why). I > applied this patch: > > --- i/src/xdisp.c > +++ w/src/xdisp.c > @@ -13936,6 +13936,11 @@ redisplay_internal (void) > if (NILP (Vmemory_full)) > prepare_menu_bars (); > > + /* prepare_menu_bars may call lisp hooks and hence change the > + selected_window. */ > + if (WINDOWP (selected_window) && (w = XWINDOW (selected_window)) != sw) > + sw = w; > + > reconsider_clip_changes (w); > > /* In most cases selected window displays current buffer. */ > > And then following the original recipe does not segfault. There is a > Lisp error, but I think that's already a bug in zoom and/or doom. Right. Please push to the emacs-26 branch, and thanks. From debbugs-submit-bounces@debbugs.gnu.org Thu May 03 03:11:29 2018 Received: (at 31312) by debbugs.gnu.org; 3 May 2018 07:11:29 +0000 Received: from localhost ([127.0.0.1]:47624 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fE8On-0004W1-7z for submit@debbugs.gnu.org; Thu, 03 May 2018 03:11:29 -0400 Received: from mout.gmx.net ([212.227.17.20]:53395) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fE8Om-0004Vm-B4 for 31312@debbugs.gnu.org; Thu, 03 May 2018 03:11:28 -0400 Received: from [192.168.1.101] ([212.95.5.30]) by mail.gmx.com (mrgmx101 [212.227.17.168]) with ESMTPSA (Nemesis) id 0LvyAz-1eI00L2KVx-017nMz; Thu, 03 May 2018 09:11:20 +0200 Message-ID: <5AEAB60F.1040604@gmx.at> Date: Thu, 03 May 2018 09:11:11 +0200 From: martin rudalics MIME-Version: 1.0 To: Eli Zaretskii Subject: Re: bug#31312: Segmentation fault with doom-emacs, NeoTree and Zoom References: <87r2mvo6c8.fsf@gmail.com> <5AE87AA3.6050602@gmx.at> <87o9hznfam.fsf@gmail.com> <5AE957BA.6000809@gmx.at> <87fu3ant8k.fsf@gmail.com> <0DFE6C67-38C5-45EE-B658-8BEF80B595FF@gnu.org> <5AE9C062.9010203@gmx.at> <831seuqeum.fsf@gnu.org> <5AEA06D2.5010208@gmx.at> <83k1slq3sn.fsf@gnu.org> In-Reply-To: <83k1slq3sn.fsf@gnu.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Provags-ID: V03:K1:AMR+mdZbKF0J+wX1HT7Sb9qQ2t26wCUfIlbYbeJPYOWNgPFzWOn hB1LuLqxK30GZXfNfzRoF3H7maSQr6uvUwGT9mBbjeqeNXwn5tvUB+4VBDWD9o89CdUTQaC vW56OY38agdSdrZTSyxpVbvPnwnf56dsgcDzWTzZ2L884asqqliR02lLEFQFGcy0UZa1NNR l+yiOm8am0z0dgwgCq2PA== X-UI-Out-Filterresults: notjunk:1;V01:K0:LRlmLbTVevc=:hgF1ZdRXMMur1Pa5Fn7RPr LROn+UPJ3RUz89UK37xpDIBzgXSPgJ1VbfRsir4mMRfdf+B23qe3f0gzqScbPJODEwl8/iQxY 7OmCW57elabeG4ttuca54aFlinzTbJbluEGdpFK+2vdWaGCgVwN3i1BhhDokeva9SWdI0PvDg C/oilI2zmFlpOUGe7gHlxGWqR+erLl/xmknNJLMWmnqF9Oqx36dUj8ohs2FTr8eP82GfzBEra acyJav40UeTno0F+A310Leg2JN54mhtDmz29H+RJVvSu1YO/i45f5Fbn2m1ahnxjpwwoHDnV+ NVzNbvwO7nZ9EVBWwzRWvGGqx33yHlQVEDZgExlmYA1bQHmt9r8un8g65HCXm38hgOIsgtK29 bdJpKM3qZbUrDXxJJ8QOzgrU5UfVzGop3EOQPJdbsHiByD3nG9+7rfdwI/TP/XwpnjpaXNa2c oZP+5q8TsxKbEX/8lKYFtVM30bKFPuexmdrmmNA72BzG2qNLvdu+vpNVumlCrp5jP9gEJgIQS jcFDxNxslYRhSBjvIHH5+26GdqUGzR38ywNtBub8crsO66iMdWPBPIQWte2LSkT1Oq7yvJ+TC rDkVt9ruJ8p3WzZSfgW3rhsze0s1AabprMM+fFcCh9n1h+jJB7ne0F0d6nzinajeHUFMxFO9q 7QF73NdQENHSlNwNAonzyzfftYFk7w1zHEJ+o5jjEQnWX/r2Liclb9DrYwNwKF4W/Jc22sWYS YcfxqemIn4aXHkhZpEffYj7IzBRW91mBgj2TQglHoSONHZOIcX6moooYOtoS+yRiOkcn5/G9p JYKm4lP X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 31312 Cc: cyrus.and@gmail.com, npostavs@gmail.com, 31312@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) > Right, and as you can see, selected_window is still a valid leaf > window when we abort in this case. Yes. I clearly misinterpreted Noam's log. martin From debbugs-submit-bounces@debbugs.gnu.org Thu May 03 08:21:44 2018 Received: (at 31312) by debbugs.gnu.org; 3 May 2018 12:21:44 +0000 Received: from localhost ([127.0.0.1]:47779 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fEDF2-0005DT-28 for submit@debbugs.gnu.org; Thu, 03 May 2018 08:21:44 -0400 Received: from mail-io0-f179.google.com ([209.85.223.179]:45467) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fEDF0-0005DG-IQ for 31312@debbugs.gnu.org; Thu, 03 May 2018 08:21:42 -0400 Received: by mail-io0-f179.google.com with SMTP id c9-v6so14999228iob.12 for <31312@debbugs.gnu.org>; Thu, 03 May 2018 05:21:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=GZ+uvVA2siREjXiwDr4iN4Pz3LXrV/kgqx4aL1U5K+8=; b=Bj2ujGpykWTTbpQD+uVWZuaY8YsJ2ONsy/eaFoK8sw1P/DchpCI6IpakykdNQtRZgP DvLKm+gAvcokyVaX0cEvDqmEAr3iWDps5W97OSCNSWBMQ/jYr2/2hm4/Q0YjLml+4mVk KkTlO+DwtelkZWHO5J00kn+V7aLp+ETDW6E1tnFBIvDxNEIbxeN4kzSGu5cjLfLfA1XI MDFT4e+XnGSPRqGNG11VqHabryHQM6GAMNpOKCgXzK77akjlNUxQhG13TB3qz6IdJIh9 7/dLILGjiLQcUF3Zu17qCSEL64ZkKUVkW/dHDKco2kDEfKVOj13KA4L2b34AVMlJ7FjC zFEw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=GZ+uvVA2siREjXiwDr4iN4Pz3LXrV/kgqx4aL1U5K+8=; b=ZMIQSuaviHW8PlloBsuJ6R31aSpACHusvV7RUr2PSJwtIVS0Iz8l+fdScshYJkhFyw dvDRKv2qGxCLIBjPQj24v73dwviM5A3HXd1qsyEC0sLq3zsuxN26KDnqIIkKQOQ2jwP4 N1iM22TWo6vFQSlpOZxdopKb0vHWD8IMyM1KmyPkAqhPxE4cxDFHRXpgjeg8yERbxc4O VA/XdbRhagyr+Z8uwJaVZ1njoZ+ZayN+SnOXc0LgU8MYTvC1HeV/0k1acn4VUShl8zK1 udAiKJiM3ledLjEKRrnMtMsCRYvcNyJLQ1ZlGUjqbWPVJc3lobHQxbz+B68Dak3lsq0K v3sg== X-Gm-Message-State: ALQs6tDkhupDJCOp4zXvqAnH2T/3v+5W4iHLGD96Ypl/v7RjUox87YVz CHayemcd1l37V0oSB5L8Grk= X-Google-Smtp-Source: AB8JxZryBldwrLxQoDUJ1FAZHavNuR/GKl+QSIEp7s3jLNWzGZeLc4bCF63+79llFcoc2bGWxliYlQ== X-Received: by 2002:a6b:3f05:: with SMTP id m5-v6mr24516325ioa.220.1525350096958; Thu, 03 May 2018 05:21:36 -0700 (PDT) Received: from zebian (cbl-45-2-119-34.yyz.frontiernetworks.ca. [45.2.119.34]) by smtp.googlemail.com with ESMTPSA id b2-v6sm2736010itg.11.2018.05.03.05.21.35 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Thu, 03 May 2018 05:21:36 -0700 (PDT) From: Noam Postavsky To: Eli Zaretskii Subject: Re: bug#31312: Segmentation fault with doom-emacs, NeoTree and Zoom References: <87r2mvo6c8.fsf@gmail.com> <5AE87AA3.6050602@gmx.at> <87o9hznfam.fsf@gmail.com> <5AE957BA.6000809@gmx.at> <87fu3ant8k.fsf@gmail.com> <0DFE6C67-38C5-45EE-B658-8BEF80B595FF@gnu.org> <5AE9C062.9010203@gmx.at> <87d0ydob8z.fsf@gmail.com> <83h8nppiyb.fsf@gnu.org> Date: Thu, 03 May 2018 08:21:34 -0400 In-Reply-To: <83h8nppiyb.fsf@gnu.org> (Eli Zaretskii's message of "Thu, 03 May 2018 05:32:44 +0300") Message-ID: <87y3h1lyk1.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 31312 Cc: rudalics@gmx.at, 31312@debbugs.gnu.org, cyrus.and@gmail.com X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Eli Zaretskii writes: > Please push to the emacs-26 branch, and thanks. Wouldn't it make sense to remove the previous check, like this? --- i/src/xdisp.c +++ w/src/xdisp.c @@ -13924,11 +13924,6 @@ redisplay_internal (void) /* Notice any pending interrupt request to change frame size. */ do_pending_window_change (true); - /* do_pending_window_change could change the selected_window due to - frame resizing which makes the selected window too small. */ - if (WINDOWP (selected_window) && (w = XWINDOW (selected_window)) != sw) - sw = w; - /* Clear frames marked as garbaged. */ clear_garbaged_frames (); @@ -13936,6 +13931,13 @@ redisplay_internal (void) if (NILP (Vmemory_full)) prepare_menu_bars (); + /* do_pending_window_change could change the selected_window due to + frame resizing which makes the selected window too small. + prepare_menu_bars may call lisp hooks and hence also change the + selected_window. */ + if (WINDOWP (selected_window) && (w = XWINDOW (selected_window)) != sw) + sw = w; + reconsider_clip_changes (w); /* In most cases selected window displays current buffer. */ From debbugs-submit-bounces@debbugs.gnu.org Thu May 03 13:54:30 2018 Received: (at 31312) by debbugs.gnu.org; 3 May 2018 17:54:30 +0000 Received: from localhost ([127.0.0.1]:48479 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fEIR4-0008WT-AY for submit@debbugs.gnu.org; Thu, 03 May 2018 13:54:30 -0400 Received: from eggs.gnu.org ([208.118.235.92]:50208) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fEIR2-0008WA-EH for 31312@debbugs.gnu.org; Thu, 03 May 2018 13:54:28 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fEIQw-0003Ff-AU for 31312@debbugs.gnu.org; Thu, 03 May 2018 13:54:23 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-0.0 required=5.0 tests=BAYES_20 autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:44519) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fEIQr-0003Dv-13; Thu, 03 May 2018 13:54:17 -0400 Received: from [176.228.60.248] (port=2208 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1fEIQq-00036p-FO; Thu, 03 May 2018 13:54:16 -0400 Date: Thu, 03 May 2018 20:54:12 +0300 Message-Id: <836044pquz.fsf@gnu.org> From: Eli Zaretskii To: Noam Postavsky In-reply-to: <87y3h1lyk1.fsf@gmail.com> (message from Noam Postavsky on Thu, 03 May 2018 08:21:34 -0400) Subject: Re: bug#31312: Segmentation fault with doom-emacs, NeoTree and Zoom References: <87r2mvo6c8.fsf@gmail.com> <5AE87AA3.6050602@gmx.at> <87o9hznfam.fsf@gmail.com> <5AE957BA.6000809@gmx.at> <87fu3ant8k.fsf@gmail.com> <0DFE6C67-38C5-45EE-B658-8BEF80B595FF@gnu.org> <5AE9C062.9010203@gmx.at> <87d0ydob8z.fsf@gmail.com> <83h8nppiyb.fsf@gnu.org> <87y3h1lyk1.fsf@gmail.com> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: 31312 Cc: rudalics@gmx.at, 31312@debbugs.gnu.org, cyrus.and@gmail.com X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Eli Zaretskii Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -6.0 (------) > From: Noam Postavsky > Cc: rudalics@gmx.at, 31312@debbugs.gnu.org, cyrus.and@gmail.com > Date: Thu, 03 May 2018 08:21:34 -0400 > > Eli Zaretskii writes: > > > Please push to the emacs-26 branch, and thanks. > > Wouldn't it make sense to remove the previous check, like this? That's a tad more risky, but I guess we can afford that. So please do. From debbugs-submit-bounces@debbugs.gnu.org Thu May 03 21:19:02 2018 Received: (at 31312) by debbugs.gnu.org; 4 May 2018 01:19:02 +0000 Received: from localhost ([127.0.0.1]:48747 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fEPNF-0002E4-KS for submit@debbugs.gnu.org; Thu, 03 May 2018 21:19:02 -0400 Received: from mail-it0-f46.google.com ([209.85.214.46]:38482) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fEPNB-0002De-Kt; Thu, 03 May 2018 21:18:59 -0400 Received: by mail-it0-f46.google.com with SMTP id q4-v6so1584784ite.3; Thu, 03 May 2018 18:18:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=kl5wKfKcjAWDD2XlLH7amMgQA1JIBNtMz49RpBdr9i8=; b=a0LMD6aJkOhTeaKiXQAF1b+Y319DdsCOiHKEFo3H3BcWYPosaquYHW/UcIftIOtByS v5fmlvp5uuqQI5I1oCskhK8ZXREa+/lMqhpvB2RDaf4d0L70j+ybL6NeCfgE+x4EEUZB 2qOtjBmMJJxHrrxPDAAH49czEWi4k423sHX8bvfnrUDV7wpnF0U+yALqutyinY0/2jtV Fvdrdxl+Q0WefyAN/4wkx8L8rKp3lXhAdWsFqpq5uKNadf6uQyTkx+0KRianYqOb8xr+ V9vhUUPRvnrjGI3KjTwf4wxKlVCPOOnf5entg59qU0FCoIdcBg5eddUHNSQ9q6Xq5bNr voqA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=kl5wKfKcjAWDD2XlLH7amMgQA1JIBNtMz49RpBdr9i8=; b=CPGl36vVI9d1qZ+M5tRBAGfZ3CvYOhD6HcqALL8HKfQOsGw7oXWZXIzIu9/rmYwEq7 ZIwmQ3vVDaObEwu8Kp4E/2eKzD0ugJ5tYaeIkN2Y9YTWGJ/vPMA1M9J42RO2U12hvYbS EA/7VEFI1FJ4qBhhA6haaPISpsRyv/f9ynIptwD5p8pdOsSBKWnpKKJ6tLDz5XCOD7FI o1tznft5xmXDGAUV2rIhEKSg5i+gsSIWwRXLu9MGgXItX6BFzaHwj4plycx1y6Nbebm3 QEzi2DOJlH0BYdWVrJAx5BDt3xVP1XeFJMBYDGsBfAgWFLcLiTruXLsVkf0+4QJmrWeY qzkA== X-Gm-Message-State: ALQs6tBY6dsQvj8QDWBRiJS5NjIxcPGuor6RHTTCwAbWZwT4wgjS3Muu v3xhhR1DwgQeN+n77JA6NVsGyQ== X-Google-Smtp-Source: AB8JxZqZuV5j9KXCYCElH70RthmPF9VHDs/CKM0EV5UClJVfiO3qQpAAn2W+jgNrApbuU+ae3XjfVA== X-Received: by 2002:a24:3989:: with SMTP id l131-v6mr27240042ita.28.1525396731816; Thu, 03 May 2018 18:18:51 -0700 (PDT) Received: from zebian (cbl-45-2-119-34.yyz.frontiernetworks.ca. [45.2.119.34]) by smtp.googlemail.com with ESMTPSA id w93-v6sm6409518ioe.87.2018.05.03.18.18.50 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Thu, 03 May 2018 18:18:50 -0700 (PDT) From: Noam Postavsky To: Eli Zaretskii Subject: Re: bug#31312: Segmentation fault with doom-emacs, NeoTree and Zoom References: <87r2mvo6c8.fsf@gmail.com> <5AE87AA3.6050602@gmx.at> <87o9hznfam.fsf@gmail.com> <5AE957BA.6000809@gmx.at> <87fu3ant8k.fsf@gmail.com> <0DFE6C67-38C5-45EE-B658-8BEF80B595FF@gnu.org> <5AE9C062.9010203@gmx.at> <87d0ydob8z.fsf@gmail.com> <83h8nppiyb.fsf@gnu.org> <87y3h1lyk1.fsf@gmail.com> <836044pquz.fsf@gnu.org> Date: Thu, 03 May 2018 21:18:49 -0400 In-Reply-To: <836044pquz.fsf@gnu.org> (Eli Zaretskii's message of "Thu, 03 May 2018 20:54:12 +0300") Message-ID: <87vac4md52.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 1.0 (+) X-Debbugs-Envelope-To: 31312 Cc: rudalics@gmx.at, 31312@debbugs.gnu.org, cyrus.and@gmail.com X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) tags 31312 fixed close 31312 26.1 quit Eli Zaretskii writes: >> From: Noam Postavsky >> Cc: rudalics@gmx.at, 31312@debbugs.gnu.org, cyrus.and@gmail.com >> Date: Thu, 03 May 2018 08:21:34 -0400 >> >> Eli Zaretskii writes: >> >> > Please push to the emacs-26 branch, and thanks. >> >> Wouldn't it make sense to remove the previous check, like this? > That's a tad more risky, but I guess we can afford that. So please > do. Done. [1: b90ce66d32]: 2018-05-03 20:58:06 -0400 Handle selected_window change in prepare_menu_bars (Bug#31312) https://git.savannah.gnu.org/cgit/emacs.git/commit/?id=b90ce66d32ede14a9191008096e596f6dfb9a48b> From unknown Sun Aug 10 16:51:42 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Fri, 01 Jun 2018 11:24:03 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator