From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Alan Third Newsgroups: gmane.emacs.bugs Subject: bug#63495: 28.2; menu crashes on macos Date: Wed, 12 Jul 2023 18:25:50 +0100 Message-ID: References: <87bkgjatup.fsf@eshelyaron.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="6920"; mail-complaints-to="usenet@ciao.gmane.io" Cc: obriendavid1@gmail.com, 63495@debbugs.gnu.org, Daniel =?UTF-8?Q?Mart=C3=ADn?= To: Eshel Yaron Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed Jul 12 19:26:20 2023 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1qJdbV-0001UI-K9 for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 12 Jul 2023 19:26:17 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qJdbJ-0006nS-6h; Wed, 12 Jul 2023 13:26:05 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qJdbH-0006nI-C0 for bug-gnu-emacs@gnu.org; Wed, 12 Jul 2023 13:26:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qJdbH-0008Ll-4k for bug-gnu-emacs@gnu.org; Wed, 12 Jul 2023 13:26:03 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qJdbG-0008HG-AQ for bug-gnu-emacs@gnu.org; Wed, 12 Jul 2023 13:26:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Alan Third Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 12 Jul 2023 17:26:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 63495 X-GNU-PR-Package: emacs Original-Received: via spool by 63495-submit@debbugs.gnu.org id=B63495.168918276031811 (code B ref 63495); Wed, 12 Jul 2023 17:26:02 +0000 Original-Received: (at 63495) by debbugs.gnu.org; 12 Jul 2023 17:26:00 +0000 Original-Received: from localhost ([127.0.0.1]:52886 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qJdbE-0008Gz-Ev for submit@debbugs.gnu.org; Wed, 12 Jul 2023 13:26:00 -0400 Original-Received: from dane.soverin.net ([185.233.34.157]:35955) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qJdbC-0008Gc-KR for 63495@debbugs.gnu.org; Wed, 12 Jul 2023 13:25:59 -0400 Original-Received: from smtp.soverin.net (c04smtp-lb01.int.sover.in [10.10.4.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by dane.soverin.net (Postfix) with ESMTPS id 4R1Plh2RFDz10XB; Wed, 12 Jul 2023 17:25:52 +0000 (UTC) Original-Received: from smtp.soverin.net (smtp.soverin.net [10.10.4.99]) by soverin.net (Postfix) with ESMTPSA id 4R1Plg5cg2zFc; Wed, 12 Jul 2023 17:25:51 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=idiocy.org; s=soverin; t=1689182752; bh=if+jvz7EtaTrpvMqZwUpwWv+HYsqKvT31LYJkJW82hI=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=Mj1+UqAqEzNwtFHpi4ZbtdjK1Yz3HYiWW2SFAQILkUPfOAsufro7MIxnb7n36rErx YDU/wO9WfGhWF23bkVdVSqghjWg7GmZJude5VrPBQwoAkedjajl6Ht7veQEFPimNL5 CwPFeQ8P10Wmz5CpuEl1dQtA/XpopIEuRMNbXnS0ITKXABBjigSTsAQKRGgxM1Tf7F omZOsTkhnF6YEL6nnIt0pZ8XwVQKwxwyP3uCEuPRxGWpEK06sBWmSQr58tQK1NC/NF n5N6Ymz0SHSM7V0Af3e7brHjYiOje7XYmJRizcbadBvblwSax7vOyg+XBApqk53vIa A2EQUeuEAw8yQ== Original-Received: from alan by faroe.holly.idiocy.org with local (Exim 4.96) (envelope-from ) id 1qJdb4-0004nJ-2G; Wed, 12 Jul 2023 18:25:50 +0100 X-Soverin-Authenticated: true Mail-Followup-To: Alan Third , Eshel Yaron , Daniel =?UTF-8?Q?Mart=C3=ADn?= , 63495@debbugs.gnu.org, obriendavid1@gmail.com Content-Disposition: inline In-Reply-To: <87bkgjatup.fsf@eshelyaron.com> X-CMAE-Score: 0 X-CMAE-Analysis: v=2.4 cv=LJ6gAra9 c=1 sm=1 tr=0 ts=64aee220 a=kj9zAlcOel0A:10 a=ws7JD89P4LkA:10 a=hIj89exaAAAA:8 a=woPl8f3k1b7UIhdEGc8A:9 a=7Zwj6sZBwVKJAoWSPKxL6X1jA+E=:19 a=CjuIK1q_8ugA:10 a=lS9wXHQM5UdnNJ4u63Ry:22 X-Cloudmark-Reporter: Sou+UQm6pxRFzGDtu8lWqa3ULXE= X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:264976 Archived-At: On Tue, Jul 11, 2023 at 08:40:46AM +0300, Eshel Yaron wrote: > Hi, > > Alan Third writes: > > > It's interesting that the crash is happening in > > runMenuAt:forFrame:keymaps: with it trying to access memory at address > > 0x3. There's nothing obvious in that function that would be doing > > that, so it would be good if we could get a backtrace from a debugger > > showing the exact line that's causing the problem and, if possible, > > which variable has the value 3. > > There's this backtrace that I've posted in Bug#62402, HTH: > > > * thread #1, queue = 'com.apple.main-thread', stop reason = EXC_BAD_ACCESS (code=1, address=0x3) > > * frame #0: 0x00000001000aebad emacs`AREF(array=0x0000000000000000, idx=0) at lisp.h:1947:10 > > frame #1: 0x00000001000af660 emacs`find_and_return_menu_selection(f=0x00000001100dee30, keymaps=true, client_data=0x000000011089b888) at menu.c:985:11 > > frame #2: 0x0000000100380f2b emacs`-[EmacsMenu runMenuAt:forFrame:keymaps:](self=0x00006000017007c0, _cmd="runMenuAt:forFrame:keymaps:", p=(x = 2, y = 506), f=0x00000001100dee30, keymaps=true) at nsmenu.m:767:9 > > frame #3: 0x0000000100381f00 emacs`ns_menu_show(f=0x00000001100dee30, x=2, y=2, menuflags=1, title=0x0000000000000000, error=0x00007ff7bfefce80) at nsmenu.m:1067:9 > > frame #4: 0x00000001000b1203 emacs`x_popup_menu_1(position=0x000000011804dcb3, menu=0x000000011804e003) at menu.c:1410:17 > > frame #5: 0x00000001000b15a2 emacs`Fx_popup_menu(position=0x000000011804dcb3, menu=0x000000011804e003) at menu.c:1474:10 > > frame #6: 0x0000000100247c58 emacs`eval_sub(form=0x000000011804dd23) at eval.c:2503:15 > > ... > > > > It seems that `find_and_return_menu_selection` in menu.c tries to > > access the global variable `menu_items` before it's initialized. I'm > > not sure when or where it should be initialized though :( No, sorry, I need the output from a debugger. That should give the exact line where the failure happens. Is anyone able to recreate this while running in a debugger? It can be lldb, doesn't have to be gcc. -- Alan Third