From unknown Sun Jun 22 03:58:00 2025 X-Loop: help-debbugs@gnu.org Subject: bug#5837: 23.1.95; Nextstep emacs -nw segfaults on startup in ns_set_doc_edited Resent-From: Steve Revilak Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 05 Apr 2010 13:49:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 5837 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: 5837@debbugs.gnu.org X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.127047533232071 (code B ref -1); Mon, 05 Apr 2010 13:49:02 +0000 Received: (at submit) by debbugs.gnu.org; 5 Apr 2010 13:48:52 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Nymfc-0008LE-3N for submit@debbugs.gnu.org; Mon, 05 Apr 2010 09:48:52 -0400 Received: from mx10.gnu.org ([199.232.76.166]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Nymfa-0008L9-LV for submit@debbugs.gnu.org; Mon, 05 Apr 2010 09:48:51 -0400 Received: from lists.gnu.org ([199.232.76.165]:42743) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1NymfV-00071Z-Hs for submit@debbugs.gnu.org; Mon, 05 Apr 2010 09:48:45 -0400 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NymfV-0007SB-1e for bug-gnu-emacs@gnu.org; Mon, 05 Apr 2010 09:48:45 -0400 Received: from [140.186.70.92] (port=46075 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NymfT-0007Rf-Cy for bug-gnu-emacs@gnu.org; Mon, 05 Apr 2010 09:48:44 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.0 (2010-01-18) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_NONE autolearn=unavailable version=3.3.0 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1NymfR-0006Q9-1f for bug-gnu-emacs@gnu.org; Mon, 05 Apr 2010 09:48:43 -0400 Received: from mail4.sea5.speakeasy.net ([69.17.117.6]:35877) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1NymfQ-0006Pv-L8 for bug-gnu-emacs@gnu.org; Mon, 05 Apr 2010 09:48:41 -0400 Received: (qmail 20866 invoked from network); 5 Apr 2010 13:48:38 -0000 Received: from pool-71-184-218-95.bstnma.fios.verizon.net (HELO srevilak.net) (srevilak@[71.184.218.95]) (envelope-sender ) by mail4.sea5.speakeasy.net (qmail-ldap-1.03) with AES256-SHA encrypted SMTP for ; 5 Apr 2010 13:48:38 -0000 Date: Mon, 5 Apr 2010 09:48:31 -0400 From: Steve Revilak Message-ID: <20100405134816.GA28589@srevilak.net> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="tjCHc7DPkfUGtrlw" Content-Disposition: inline User-Agent: Mutt/1.5.20 (2009-06-14) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6, seldom 2.4 (older, 4) X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6, seldom 2.4 (older, 4) X-Spam-Score: -3.3 (---) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -4.8 (----) --tjCHc7DPkfUGtrlw Content-Type: text/plain; charset=us-ascii; format=flowed Content-Disposition: inline This bug report will be sent to the Free Software Foundation, not to your local site managers! Please write in English if possible, because the Emacs maintainers usually do not have translators to read other languages for them. * * * I've just built emacs 23.1.95 on two Mac OS X systems; one Mac OS 10.6.2 (x86_64), and one Mac OS 10.4.11 (PPC G5). On both systems "emacs -nw" segfaults on startup. The segfault happens so early that I cannot use M-x report-emacs-bug on the affected systems. When I run emacs as a windowed application (without "-nw"), then there is no segfault. Emacs was configured as "./configure --with-ns". I've looked through the emacs-devel archive, and found one thread that discusses a similar crash: http://lists.gnu.org/archive/html/emacs-devel/2010-04/msg00075.html In my case, the crash happens in a different place (ns_set_doc_edited, as opposed to alloc.c). Here is a gdb session + backtrace taken Mac OS X 10.6.2. The gdb session shows emacs being started with "-nw -Q". The presence (or absense) of "-Q" doesn't seem to change the segfault behavior. ------------------------------------------------------------------ (0:0)oatmeal:bin$ gdb /Applications/Emacs.app/Contents/MacOS/Emacs GNU gdb 6.3.50-20050815 (Apple version gdb-1346) (Fri Sep 18 20:40:51 UTC 2009) Copyright 2004 Free Software Foundation, Inc. GDB is free software, covered by the GNU General Public License, and you are welcome to change it and/or distribute copies of it under certain conditions. Type "show copying" to see the conditions. There is absolutely no warranty for GDB. Type "show warranty" for details. This GDB was configured as "x86_64-apple-darwin"... Reading symbols for shared libraries ......... done (gdb) set args -Q -nw (gdb) run Program received signal EXC_BAD_ACCESS, Could not access memory. Reason: KERN_INVALID_ADDRESS at address: 0x0000000000000000 0x0000000100178b46 in ns_set_doc_edited (f=0x101506f08, arg=4320133130) at nsfns.m:691 691 NSView *view = FRAME_NS_VIEW (f); (gdb) bt #0 0x0000000100178b46 in ns_set_doc_edited (f=0x101506f08, arg=4320133130) at nsfns.m:691 #1 0x0000000100037e3c in prepare_menu_bars () at xdisp.c:9574 #2 0x000000010004140a in redisplay_internal (preserve_echo_area=) at xdisp.c:11430 #3 0x000000010009e81e in read_char (commandflag=1, nmaps=2, maps=0x7fff5fbfed00, prev_event=4320133130, used_mouse_menu=0x7fff5fbfee44, end_time=0x0) at keyboard.c:2727 #4 0x00000001000a0faf in read_key_sequence (keybuf=0x7fff5fbfeee0, bufsize=30, prompt=4320133130, dont_downcase_last=0, can_return_switch_frame=1, fix_current_buffer=1) at keyboard.c:9512 #5 0x00000001000a352b in command_loop_1 () at keyboard.c:1643 #6 0x0000000100107637 in internal_condition_case (bfun=0x1000a32e0 , handlers=4320204170, hfun=0x10009b580 ) at eval.c:1490 #7 0x000000010009a907 in command_loop_2 () at keyboard.c:1360 #8 0x0000000100107740 in internal_catch (tag=, func=0x10009a8d0 , arg=4320133130) at eval.c:1226 #9 0x000000010009b396 in command_loop () at keyboard.c:1339 #10 0x000000010009b7ff in recursive_edit_1 () at keyboard.c:954 #11 0x000000010009b99f in Frecursive_edit () at keyboard.c:1016 #12 0x0000000100090f87 in main (argc=3, argv=0x7fff5fbff4b8) at emacs.c:1833 Current language: auto; currently objective-c (gdb) p view $2 = (gdb) p *view Cannot access memory at address 0x0 (gdb) p *f $3 = { size = 4611686018427388949, next = 0x1015067e8, name = 4296987921, icon_name = 4320133130, title = 4320133130, focus_frame = 4320133130, root_window = 4317016477, selected_window = 4317016477, minibuffer_window = 4317017085, param_alist = 4345638054, scroll_bars = 4320133130, condemned_scroll_bars = 4320133130, menu_bar_items = 4303773861, face_alist = 4323932566, menu_bar_vector = 4320133130, buffer_predicate = 4320133130, buffer_list = 4320157334, buried_buffer_list = 4320133130, menu_bar_window = 4320133130, tool_bar_window = 4320133130, tool_bar_items = 4320133130, desired_tool_bar_string = 4320133130, current_tool_bar_string = 4320133130, face_cache = 0x101555108, menu_bar_items_used = 0, namebuf = 0x0, current_pool = 0x10080c9f0, desired_pool = 0x10080c9d0, desired_matrix = 0x10080ca10, current_matrix = 0x10080cc70, glyphs_initialized_p = 1, resized_p = 0, force_flush_display_p = 1, default_face_done_p = 0, already_hscrolled_p = 0, updated_p = 0, minimize_tool_bar_window_p = 0, external_tool_bar = 0, tool_bar_lines = 0, n_tool_bar_rows = 0, n_tool_bar_items = 0, decode_mode_spec_buffer = 0x10080db90 '-' ..., insert_line_cost = 0x10080e010, delete_line_cost = 0x10080e220, insert_n_lines_cost = 0x10080e170, delete_n_lines_cost = 0x10080e0c0, text_lines = 43, text_cols = 95, total_lines = 0, total_cols = 95, new_text_lines = 0, new_text_cols = 0, left_pos = 0, top_pos = 0, pixel_height = 0, pixel_width = 0, resx = 0, resy = 0, x_pixels_diff = 0, y_pixels_diff = 0, win_gravity = 0, size_hint_flags = 0, border_width = 0, internal_border_width = 0, column_width = 1, space_width = 0, line_height = 1, output_method = output_termcap, terminal = 0x10080b250, output_data = { tty = 0x0, x = 0x0, w32 = 0x0, ns = 0x0, nothing = 0 }, font_driver_list = 0x0, font_data_list = 0x0, fringe_cols = 0, left_fringe_width = 0, right_fringe_width = 0, want_fullscreen = FULLSCREEN_NONE, menu_bar_lines = 1, external_menu_bar = 0, display_preempted = 0 '\000', visible = 1 '\001', iconified = 0 '\000', async_visible = 1 '\001', async_iconified = 0 '\000', garbaged = 0 '\000', has_minibuffer = 1 '\001', wants_modeline = 1 '\001', can_have_scroll_bars = 0 '\000', auto_raise = 0 '\000', auto_lower = 0 '\000', no_split = 0 '\000', explicit_name = 0 '\000', window_sizes_changed = 0 '\000', mouse_moved = 0 '\000', pointer_invisible = 0 '\000', vertical_scroll_bar_type = vertical_scroll_bar_none, desired_cursor = FILLED_BOX_CURSOR, cursor_width = 0, blink_off_cursor = FILLED_BOX_CURSOR, blink_off_cursor_width = 0, message_buf = 0x10080da10 "", scroll_bottom_vpos = 0, config_scroll_bar_width = 0, config_scroll_bar_cols = 0, scroll_bar_actual_width = 0, cost_calculation_baud_rate = 9600, alpha = {0, 0}, gamma = 0, extra_line_spacing = 0, background_pixel = 18446744073709551613, foreground_pixel = 18446744073709551614 } (0:0)oatmeal:~$ uname -a Darwin oatmeal 10.2.0 Darwin Kernel Version 10.2.0: Tue Nov 3 10:37:10 PST 2009; root:xnu-1486.2.11~1/RELEASE_I386 i386 (0:0)oatmeal:~$ sw_vers ProductName: Mac OS X ProductVersion: 10.6.2 BuildVersion: 10C540 ------------------------------------------------------------------ --tjCHc7DPkfUGtrlw Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.12 (GNU/Linux) iEYEARECAAYFAku56i8ACgkQX7YJI4BuyDSfrQCcCg7ReXNLUOaeYVkZuuVf5bLw ok8An2jus+teRdkc7fvjOSUwCnW2R0g8 =9/pH -----END PGP SIGNATURE----- --tjCHc7DPkfUGtrlw-- From unknown Sun Jun 22 03:58:00 2025 X-Loop: help-debbugs@gnu.org Subject: bug#5837: 23.1.95; Nextstep emacs -nw segfaults on startup in ns_set_doc_edited Resent-From: Chong Yidong Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 05 Apr 2010 14:07:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 5837 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Steve Revilak Cc: 5837@debbugs.gnu.org Received: via spool by 5837-submit@debbugs.gnu.org id=B5837.127047638832560 (code B ref 5837); Mon, 05 Apr 2010 14:07:01 +0000 Received: (at 5837) by debbugs.gnu.org; 5 Apr 2010 14:06:28 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Nymwe-0008T7-H7 for submit@debbugs.gnu.org; Mon, 05 Apr 2010 10:06:28 -0400 Received: from pantheon-po35.its.yale.edu ([130.132.50.83]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Nymwc-0008T0-DJ for 5837@debbugs.gnu.org; Mon, 05 Apr 2010 10:06:26 -0400 Received: from furry (dhcp128036014175.central.yale.edu [128.36.14.175]) (authenticated bits=0) by pantheon-po35.its.yale.edu (8.12.11.20060308/8.12.11) with ESMTP id o35E6KlH021159 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Mon, 5 Apr 2010 10:06:21 -0400 Received: by furry (Postfix, from userid 1000) id 0A75CC055; Mon, 5 Apr 2010 10:06:19 -0400 (EDT) From: Chong Yidong References: <20100405134816.GA28589@srevilak.net> Date: Mon, 05 Apr 2010 10:06:19 -0400 In-Reply-To: <20100405134816.GA28589@srevilak.net> (Steve Revilak's message of "Mon, 5 Apr 2010 09:48:31 -0400") Message-ID: <87hbnqhu3o.fsf@stupidchicken.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1.95 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-YaleITSMailFilter: Version 1.2c (attachment(s) not renamed) X-Spam-Score: -2.8 (--) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.8 (--) Steve Revilak writes: > I've just built emacs 23.1.95 on two Mac OS X systems; one Mac OS > 10.6.2 (x86_64), and one Mac OS 10.4.11 (PPC G5). On both systems > "emacs -nw" segfaults on startup. The segfault happens so early that > I cannot use M-x report-emacs-bug on the affected systems. > > When I run emacs as a windowed application (without "-nw"), then there > is no segfault. Thanks for the bug report. Does the following patch fix the problem? === modified file 'src/xdisp.c' *** src/xdisp.c 2010-03-30 17:26:58 +0000 --- src/xdisp.c 2010-04-05 14:05:48 +0000 *************** *** 9570,9576 **** update_tool_bar (f, 0); #endif #ifdef HAVE_NS ! if (windows_or_buffers_changed) ns_set_doc_edited (f, Fbuffer_modified_p (XWINDOW (f->selected_window)->buffer)); #endif --- 9570,9577 ---- update_tool_bar (f, 0); #endif #ifdef HAVE_NS ! if (windows_or_buffers_changed ! && FRAME_NS_P (f)) ns_set_doc_edited (f, Fbuffer_modified_p (XWINDOW (f->selected_window)->buffer)); #endif From unknown Sun Jun 22 03:58:00 2025 X-Loop: help-debbugs@gnu.org Subject: bug#5837: 23.1.95; Nextstep emacs -nw segfaults on startup in ns_set_doc_edited Resent-From: Eli Zaretskii Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 05 Apr 2010 14:13:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 5837 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Steve Revilak Cc: 5837@debbugs.gnu.org Received: via spool by 5837-submit@debbugs.gnu.org id=B5837.127047677732724 (code B ref 5837); Mon, 05 Apr 2010 14:13:02 +0000 Received: (at 5837) by debbugs.gnu.org; 5 Apr 2010 14:12:57 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Nyn2u-0008Vl-Pu for submit@debbugs.gnu.org; Mon, 05 Apr 2010 10:12:56 -0400 Received: from mtaout20.012.net.il ([80.179.55.166]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Nyn2r-0008Vg-H8 for 5837@debbugs.gnu.org; Mon, 05 Apr 2010 10:12:55 -0400 Received: from conversion-daemon.a-mtaout20.012.net.il by a-mtaout20.012.net.il (HyperSendmail v2007.08) id <0L0E00G00P3R3X00@a-mtaout20.012.net.il> for 5837@debbugs.gnu.org; Mon, 05 Apr 2010 17:12:22 +0300 (IDT) Received: from HOME-C4E4A596F7 ([77.124.92.42]) by a-mtaout20.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0L0E00BONQ4LZ2G0@a-mtaout20.012.net.il>; Mon, 05 Apr 2010 17:12:22 +0300 (IDT) Date: Mon, 05 Apr 2010 17:12:28 +0300 From: Eli Zaretskii In-reply-to: <20100405134816.GA28589@srevilak.net> X-012-Sender: halo1@inter.net.il Message-id: <836346yomr.fsf@gnu.org> References: <20100405134816.GA28589@srevilak.net> X-Spam-Score: -1.8 (-) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.8 (-) > Date: Mon, 5 Apr 2010 09:48:31 -0400 > From: Steve Revilak > Cc: > > I've just built emacs 23.1.95 on two Mac OS X systems; one Mac OS > 10.6.2 (x86_64), and one Mac OS 10.4.11 (PPC G5). On both systems > "emacs -nw" segfaults on startup. The segfault happens so early that > I cannot use M-x report-emacs-bug on the affected systems. > > When I run emacs as a windowed application (without "-nw"), then there > is no segfault. > > Emacs was configured as "./configure --with-ns". > > I've looked through the emacs-devel archive, and found one thread that > discusses a similar crash: > > http://lists.gnu.org/archive/html/emacs-devel/2010-04/msg00075.html > > In my case, the crash happens in a different place (ns_set_doc_edited, > as opposed to alloc.c). That crash is different, I think: it's in a middle of GC, and in a general area of Emacs code. Your crash is in NS-specific code. But it looks very similar, if not identical, to bug#5834. From unknown Sun Jun 22 03:58:00 2025 MIME-Version: 1.0 X-Mailer: MIME-tools 5.427 (Entity 5.427) X-Loop: help-debbugs@gnu.org From: help-debbugs@gnu.org (GNU bug Tracking System) To: Steve Revilak Subject: bug#5837 closed by Steve Revilak (Re: bug#5837: 23.1.95; Nextstep emacs -nw segfaults on startup in ns_set_doc_edited) Message-ID: References: <20100405142551.GC28589@srevilak.net> <20100405134816.GA28589@srevilak.net> X-Gnu-PR-Message: they-closed 5837 X-Gnu-PR-Package: emacs Reply-To: 5837@debbugs.gnu.org Date: Mon, 05 Apr 2010 14:27:02 +0000 Content-Type: multipart/mixed; boundary="----------=_1270477622-598-1" This is a multi-part message in MIME format... ------------=_1270477622-598-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" This is an automatic notification regarding your bug report which was filed against the emacs package: #5837: 23.1.95; Nextstep emacs -nw segfaults on startup in ns_set_doc_edited It has been closed by Steve Revilak . Their explanation is attached below along with your original report. If this explanation is unsatisfactory and you have not received a better one in a separate message then please contact Steve Revilak by replying to this email. --=20 5837: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D5837 GNU Bug Tracking System Contact help-debbugs@gnu.org with problems ------------=_1270477622-598-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at 5837-done) by debbugs.gnu.org; 5 Apr 2010 14:26:03 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1NynFb-00009N-0S for submit@debbugs.gnu.org; Mon, 05 Apr 2010 10:26:03 -0400 Received: from mail6.sea5.speakeasy.net ([69.17.117.8]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1NynFY-00008v-R1 for 5837-done@debbugs.gnu.org; Mon, 05 Apr 2010 10:26:01 -0400 Received: (qmail 29432 invoked from network); 5 Apr 2010 14:25:54 -0000 Received: from pool-71-184-218-95.bstnma.fios.verizon.net (HELO srevilak.net) (srevilak@[71.184.218.95]) (envelope-sender ) by mail6.sea5.speakeasy.net (qmail-ldap-1.03) with AES256-SHA encrypted SMTP for ; 5 Apr 2010 14:25:54 -0000 Date: Mon, 5 Apr 2010 10:25:51 -0400 From: Steve Revilak To: Chong Yidong Subject: Re: bug#5837: 23.1.95; Nextstep emacs -nw segfaults on startup in ns_set_doc_edited Message-ID: <20100405142551.GC28589@srevilak.net> References: <20100405134816.GA28589@srevilak.net> <87hbnqhu3o.fsf@stupidchicken.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="FFoLq8A0u+X9iRU8" Content-Disposition: inline In-Reply-To: <87hbnqhu3o.fsf@stupidchicken.com> User-Agent: Mutt/1.5.20 (2009-06-14) X-Spam-Score: -3.3 (---) X-Debbugs-Envelope-To: 5837-done Cc: 5837-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -3.1 (---) --FFoLq8A0u+X9iRU8 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Disposition: inline >Thanks for the bug report. Does the following patch fix the problem? Chong, Thanks for the patch. This fixes the crash on both Mac OS X 10.4.11 and Mac OS X 10.6.2. Steve --FFoLq8A0u+X9iRU8 Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.12 (GNU/Linux) iEYEARECAAYFAku58u8ACgkQX7YJI4BuyDQCZwCg2CZTcH2/25RMAZwLB1DGDXa/ P0MAoICGYuRKKxmuVrXJMnQ7YlZh6veH =mXEd -----END PGP SIGNATURE----- --FFoLq8A0u+X9iRU8-- ------------=_1270477622-598-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at submit) by debbugs.gnu.org; 5 Apr 2010 13:48:52 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Nymfc-0008LE-3N for submit@debbugs.gnu.org; Mon, 05 Apr 2010 09:48:52 -0400 Received: from mx10.gnu.org ([199.232.76.166]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Nymfa-0008L9-LV for submit@debbugs.gnu.org; Mon, 05 Apr 2010 09:48:51 -0400 Received: from lists.gnu.org ([199.232.76.165]:42743) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1NymfV-00071Z-Hs for submit@debbugs.gnu.org; Mon, 05 Apr 2010 09:48:45 -0400 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NymfV-0007SB-1e for bug-gnu-emacs@gnu.org; Mon, 05 Apr 2010 09:48:45 -0400 Received: from [140.186.70.92] (port=46075 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NymfT-0007Rf-Cy for bug-gnu-emacs@gnu.org; Mon, 05 Apr 2010 09:48:44 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.0 (2010-01-18) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_NONE autolearn=unavailable version=3.3.0 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1NymfR-0006Q9-1f for bug-gnu-emacs@gnu.org; Mon, 05 Apr 2010 09:48:43 -0400 Received: from mail4.sea5.speakeasy.net ([69.17.117.6]:35877) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1NymfQ-0006Pv-L8 for bug-gnu-emacs@gnu.org; Mon, 05 Apr 2010 09:48:41 -0400 Received: (qmail 20866 invoked from network); 5 Apr 2010 13:48:38 -0000 Received: from pool-71-184-218-95.bstnma.fios.verizon.net (HELO srevilak.net) (srevilak@[71.184.218.95]) (envelope-sender ) by mail4.sea5.speakeasy.net (qmail-ldap-1.03) with AES256-SHA encrypted SMTP for ; 5 Apr 2010 13:48:38 -0000 Date: Mon, 5 Apr 2010 09:48:31 -0400 From: Steve Revilak To: bug-gnu-emacs@gnu.org Subject: 23.1.95; Nextstep emacs -nw segfaults on startup in ns_set_doc_edited Message-ID: <20100405134816.GA28589@srevilak.net> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="tjCHc7DPkfUGtrlw" Content-Disposition: inline User-Agent: Mutt/1.5.20 (2009-06-14) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6, seldom 2.4 (older, 4) X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6, seldom 2.4 (older, 4) X-Spam-Score: -3.3 (---) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -4.8 (----) --tjCHc7DPkfUGtrlw Content-Type: text/plain; charset=us-ascii; format=flowed Content-Disposition: inline This bug report will be sent to the Free Software Foundation, not to your local site managers! Please write in English if possible, because the Emacs maintainers usually do not have translators to read other languages for them. * * * I've just built emacs 23.1.95 on two Mac OS X systems; one Mac OS 10.6.2 (x86_64), and one Mac OS 10.4.11 (PPC G5). On both systems "emacs -nw" segfaults on startup. The segfault happens so early that I cannot use M-x report-emacs-bug on the affected systems. When I run emacs as a windowed application (without "-nw"), then there is no segfault. Emacs was configured as "./configure --with-ns". I've looked through the emacs-devel archive, and found one thread that discusses a similar crash: http://lists.gnu.org/archive/html/emacs-devel/2010-04/msg00075.html In my case, the crash happens in a different place (ns_set_doc_edited, as opposed to alloc.c). Here is a gdb session + backtrace taken Mac OS X 10.6.2. The gdb session shows emacs being started with "-nw -Q". The presence (or absense) of "-Q" doesn't seem to change the segfault behavior. ------------------------------------------------------------------ (0:0)oatmeal:bin$ gdb /Applications/Emacs.app/Contents/MacOS/Emacs GNU gdb 6.3.50-20050815 (Apple version gdb-1346) (Fri Sep 18 20:40:51 UTC 2009) Copyright 2004 Free Software Foundation, Inc. GDB is free software, covered by the GNU General Public License, and you are welcome to change it and/or distribute copies of it under certain conditions. Type "show copying" to see the conditions. There is absolutely no warranty for GDB. Type "show warranty" for details. This GDB was configured as "x86_64-apple-darwin"... Reading symbols for shared libraries ......... done (gdb) set args -Q -nw (gdb) run Program received signal EXC_BAD_ACCESS, Could not access memory. Reason: KERN_INVALID_ADDRESS at address: 0x0000000000000000 0x0000000100178b46 in ns_set_doc_edited (f=0x101506f08, arg=4320133130) at nsfns.m:691 691 NSView *view = FRAME_NS_VIEW (f); (gdb) bt #0 0x0000000100178b46 in ns_set_doc_edited (f=0x101506f08, arg=4320133130) at nsfns.m:691 #1 0x0000000100037e3c in prepare_menu_bars () at xdisp.c:9574 #2 0x000000010004140a in redisplay_internal (preserve_echo_area=) at xdisp.c:11430 #3 0x000000010009e81e in read_char (commandflag=1, nmaps=2, maps=0x7fff5fbfed00, prev_event=4320133130, used_mouse_menu=0x7fff5fbfee44, end_time=0x0) at keyboard.c:2727 #4 0x00000001000a0faf in read_key_sequence (keybuf=0x7fff5fbfeee0, bufsize=30, prompt=4320133130, dont_downcase_last=0, can_return_switch_frame=1, fix_current_buffer=1) at keyboard.c:9512 #5 0x00000001000a352b in command_loop_1 () at keyboard.c:1643 #6 0x0000000100107637 in internal_condition_case (bfun=0x1000a32e0 , handlers=4320204170, hfun=0x10009b580 ) at eval.c:1490 #7 0x000000010009a907 in command_loop_2 () at keyboard.c:1360 #8 0x0000000100107740 in internal_catch (tag=, func=0x10009a8d0 , arg=4320133130) at eval.c:1226 #9 0x000000010009b396 in command_loop () at keyboard.c:1339 #10 0x000000010009b7ff in recursive_edit_1 () at keyboard.c:954 #11 0x000000010009b99f in Frecursive_edit () at keyboard.c:1016 #12 0x0000000100090f87 in main (argc=3, argv=0x7fff5fbff4b8) at emacs.c:1833 Current language: auto; currently objective-c (gdb) p view $2 = (gdb) p *view Cannot access memory at address 0x0 (gdb) p *f $3 = { size = 4611686018427388949, next = 0x1015067e8, name = 4296987921, icon_name = 4320133130, title = 4320133130, focus_frame = 4320133130, root_window = 4317016477, selected_window = 4317016477, minibuffer_window = 4317017085, param_alist = 4345638054, scroll_bars = 4320133130, condemned_scroll_bars = 4320133130, menu_bar_items = 4303773861, face_alist = 4323932566, menu_bar_vector = 4320133130, buffer_predicate = 4320133130, buffer_list = 4320157334, buried_buffer_list = 4320133130, menu_bar_window = 4320133130, tool_bar_window = 4320133130, tool_bar_items = 4320133130, desired_tool_bar_string = 4320133130, current_tool_bar_string = 4320133130, face_cache = 0x101555108, menu_bar_items_used = 0, namebuf = 0x0, current_pool = 0x10080c9f0, desired_pool = 0x10080c9d0, desired_matrix = 0x10080ca10, current_matrix = 0x10080cc70, glyphs_initialized_p = 1, resized_p = 0, force_flush_display_p = 1, default_face_done_p = 0, already_hscrolled_p = 0, updated_p = 0, minimize_tool_bar_window_p = 0, external_tool_bar = 0, tool_bar_lines = 0, n_tool_bar_rows = 0, n_tool_bar_items = 0, decode_mode_spec_buffer = 0x10080db90 '-' ..., insert_line_cost = 0x10080e010, delete_line_cost = 0x10080e220, insert_n_lines_cost = 0x10080e170, delete_n_lines_cost = 0x10080e0c0, text_lines = 43, text_cols = 95, total_lines = 0, total_cols = 95, new_text_lines = 0, new_text_cols = 0, left_pos = 0, top_pos = 0, pixel_height = 0, pixel_width = 0, resx = 0, resy = 0, x_pixels_diff = 0, y_pixels_diff = 0, win_gravity = 0, size_hint_flags = 0, border_width = 0, internal_border_width = 0, column_width = 1, space_width = 0, line_height = 1, output_method = output_termcap, terminal = 0x10080b250, output_data = { tty = 0x0, x = 0x0, w32 = 0x0, ns = 0x0, nothing = 0 }, font_driver_list = 0x0, font_data_list = 0x0, fringe_cols = 0, left_fringe_width = 0, right_fringe_width = 0, want_fullscreen = FULLSCREEN_NONE, menu_bar_lines = 1, external_menu_bar = 0, display_preempted = 0 '\000', visible = 1 '\001', iconified = 0 '\000', async_visible = 1 '\001', async_iconified = 0 '\000', garbaged = 0 '\000', has_minibuffer = 1 '\001', wants_modeline = 1 '\001', can_have_scroll_bars = 0 '\000', auto_raise = 0 '\000', auto_lower = 0 '\000', no_split = 0 '\000', explicit_name = 0 '\000', window_sizes_changed = 0 '\000', mouse_moved = 0 '\000', pointer_invisible = 0 '\000', vertical_scroll_bar_type = vertical_scroll_bar_none, desired_cursor = FILLED_BOX_CURSOR, cursor_width = 0, blink_off_cursor = FILLED_BOX_CURSOR, blink_off_cursor_width = 0, message_buf = 0x10080da10 "", scroll_bottom_vpos = 0, config_scroll_bar_width = 0, config_scroll_bar_cols = 0, scroll_bar_actual_width = 0, cost_calculation_baud_rate = 9600, alpha = {0, 0}, gamma = 0, extra_line_spacing = 0, background_pixel = 18446744073709551613, foreground_pixel = 18446744073709551614 } (0:0)oatmeal:~$ uname -a Darwin oatmeal 10.2.0 Darwin Kernel Version 10.2.0: Tue Nov 3 10:37:10 PST 2009; root:xnu-1486.2.11~1/RELEASE_I386 i386 (0:0)oatmeal:~$ sw_vers ProductName: Mac OS X ProductVersion: 10.6.2 BuildVersion: 10C540 ------------------------------------------------------------------ --tjCHc7DPkfUGtrlw Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.12 (GNU/Linux) iEYEARECAAYFAku56i8ACgkQX7YJI4BuyDSfrQCcCg7ReXNLUOaeYVkZuuVf5bLw ok8An2jus+teRdkc7fvjOSUwCnW2R0g8 =9/pH -----END PGP SIGNATURE----- --tjCHc7DPkfUGtrlw-- ------------=_1270477622-598-1--