Subject: Re: bug#18925: On Mac emacs -nw crashes, emacs doesn't

From: "Jan D." <[email-masked]>
Date: Mon, 03 Nov 2014 08:18:20 +0100

Eli Zaretskii skrev den 2014-11-02 19:57:
>> From: David Kanter <[email-masked]>
>> Date: Sun, 02 Nov 2014 11:56:06 -0500
>>
>> I track emacs-24 using bzr on my Mac, and build Emacs.app using
>> --with-ns. Over the last few days emacs -nw crashes on startup, but the
>> NeXTstep emacs works fine.
>>
>> When I start emacs -nw at the terminal, I get
>>
>> Fatal error 11: Segmentation faultAbort
>>
>> and come back to the prompt. Below is the crash report generated by the
>> Mac. (I don't think I can do report-emacs-bug if Emacs doesn't start,
>> right?)
>
> You can report-emacs-bug from a GUI session.
>
>> Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
>> 0   libsystem_kernel.dylib        	0x00007fff8d394292 __kill + 10
>> 1   org.gnu.Emacs                 	0x00000001000b82f4 terminate_due_to_signal + 148 (emacs.c:378)
>> 2   org.gnu.Emacs                 	0x00000001000d5733 emacs_abort + 19
>> 3   org.gnu.Emacs                 	0x00000001001a736c ns_term_shutdown + 124
>> 4   org.gnu.Emacs                 	0x00000001000b84eb shut_down_emacs + 283 (emacs.c:2054)
>> 5   org.gnu.Emacs                 	0x00000001000b82b9 terminate_due_to_signal + 89 (emacs.c:363)
>> 6   org.gnu.Emacs                 	0x00000001000d7066 deliver_fatal_thread_signal + 134
>> 7   libsystem_platform.dylib      	0x00007fff913b25aa _sigtramp + 26
>> 8   ???                           	000000000000000000 0 + 0
>> 9   org.gnu.Emacs                 	0x00000001000266da redisplay_internal + 7258 (xdisp.c:13957)
>
> What is on line 13957 of xdisp.c in the sources used to build this
> binary?  I'm asking because in the sources I have here, that line
> says:
>
>                   if (interrupt_input)
>
> which cannot possibly segfault.

Stack smashing makes the backtrace unreliable.  It was not xdisp.c, but 
nsfns.m.  Maybe that is the 8 ??? above.

	Jan D.