Subject: Re: bug#35204: 27.0.50; Crash on Cygwin

From: Eli Zaretskii <[email-masked]>
Date: Tue, 09 Apr 2019 12:47:52 +0300

> Date: Tue, 09 Apr 2019 17:07:58 +0900
> From: Katsumi Yamaoka <[email-masked]>
> 
> Here is a gdb backtrace I got after reverting only 1.:
> 
> (gdb) bt
> #0  0x000000010054a66a in terminate_due_to_signal ()
> #1  0x000000010057110d in handle_fatal_signal ()
> #2  0x00000001005710e0 in deliver_thread_signal ()
> #3  0x0000000100571149 in deliver_fatal_thread_signal ()
> #4  0x0000000100571361 in handle_sigsegv ()
> #5  0x000000018005f65a in altstack_wrapper (sig=<optimized out>, 
>     siginfo=<optimized out>, sigctx=0xffffde50, 
>     handler=0x1005712a5 <handle_sigsegv>)
>     at /usr/src/debug/cygwin-3.0.6-1/winsup/cygwin/exceptions.cc:1595
> #6  0x0000000180062dfa in _cygtls::call_signal_handler (this=0xffffce00)
>     at /usr/src/debug/cygwin-3.0.6-1/winsup/cygwin/exceptions.cc:1777
> #7  0x0000000000000000 in ?? ()

Is this when you run Emacs from GDB to begin with?  If not, please run
Emacs from GDB, then the backtrace should be more informative.

> I couldn't fetch a backtrace for Emacs before reverting because
> of an error:
> 
> (gdb) bt
> #0  0x000000010054a72f in terminate_due_to_signal ()
> #1  0x000303e90000faf0 in ?? ()
> Backtrace stopped: previous frame inner to this frame (corrupt stack?)

How many threads are in the process?  Did you type "bt" when the Lisp
thread was the current one?

> Couldn't fetch xbacktrace either:
> 
> (gdb) source .gdbinit
> SIGINT is used by the debugger.
> Are you sure you want to change it? (y or n) [answered Y; input not from terminal]
> DISPLAY = :0.0
> TERM = xterm
> Breakpoint 1 at 0x10054a66a
> .gdbinit:1228: Error in sourced command file:
> No symbol "defined_HAVE_X_WINDOWS" in current context.

Did you build Emacs with -g3 switch to GCC?