Subject: bug#13007: 24.3.50; emacs_backtrace.txt

From: Eli Zaretskii <[email-masked]>
Date: Tue, 27 Nov 2012 17:14:02 +0200

> From: "Drew Adams" <[email-masked]>
> Date: Mon, 26 Nov 2012 22:23:50 -0800
> 
> In case it helps, here is an emacs_backtrace.txt.  AFAIK, I wasn't doing
> anything particular at the moment (usual use), and I had started Emacs
> only about 30 sec before the crash.

Thanks, it does help.  The backtrace produced by addr2line is below.

The crash is due to assertion violation here:

  static int
  window_outdated (struct window *w)
  {
    eassert (XBUFFER (w->buffer) == current_buffer);  <<<<<<<<<<<<<<<<<<
    return (w->last_modified < MODIFF 
	    || w->last_overlay_modified < OVERLAY_MODIFF);
  }

Dmitry, why did you add this assertion?  What code that you introduced
assumes that this condition is always true?

I suspect that we need to change this assertion to

    eassert (MINI_WINDOW_P (w) || w->pseudo_window_p
             || XBUFFER (w->buffer) == current_buffer);

At least in this case (see the backtrace below), window_outdated is
called from code that handles minibuffer windows, so I'm guessing the
above assertion is not true.

Here's the full backtrace:

  w32_backtrace at C:\emacs\trunk\src/w32fns.c:7735
  emacs_abort at C:\emacs\trunk\src/w32fns.c:7767
  terminate_due_to_signal at C:\emacs\trunk\src/emacs.c:341
  die at C:\emacs\trunk\src/alloc.c:6487
  window_outdated at C:\emacs\trunk\src/xdisp.c:10906
  redisplay_internal at C:\emacs\trunk\src/xdisp.c:13213
  redisplay at C:\emacs\trunk\src/xdisp.c:12715
  read_char at C:\emacs\trunk\src/keyboard.c:2416
  read_filtered_event at C:\emacs\trunk\src/lread.c:609
  Fread_event at C:\emacs\trunk\src/lread.c:721
  Ffuncall at C:\emacs\trunk\src/eval.c:2678
  exec_byte_code at C:\emacs\trunk\src/bytecode.c:899
  funcall_lambda at C:\emacs\trunk\src/eval.c:2903
  Ffuncall at C:\emacs\trunk\src/eval.c:2720
  exec_byte_code at C:\emacs\trunk\src/bytecode.c:899
  funcall_lambda at C:\emacs\trunk\src/eval.c:2903
  Ffuncall at C:\emacs\trunk\src/eval.c:2720
  exec_byte_code at C:\emacs\trunk\src/bytecode.c:899
  funcall_lambda at C:\emacs\trunk\src/eval.c:2903
  Ffuncall at C:\emacs\trunk\src/eval.c:2720
  exec_byte_code at C:\emacs\trunk\src/bytecode.c:899
  funcall_lambda at C:\emacs\trunk\src/eval.c:2903
  Ffuncall at C:\emacs\trunk\src/eval.c:2720
  exec_byte_code at C:\emacs\trunk\src/bytecode.c:899
  funcall_lambda at C:\emacs\trunk\src/eval.c:2903
  Ffuncall at C:\emacs\trunk\src/eval.c:2720
  apply1 at C:\emacs\trunk\src/eval.c:2432
  Fcall_interactively at C:\emacs\trunk\src/callint.c:377
  Ffuncall at C:\emacs\trunk\src/eval.c:2678
  call3 at C:\emacs\trunk\src/eval.c:2496
  Fcommand_execute at C:\emacs\trunk\src/keyboard.c:10214
  command_loop_1 at C:\emacs\trunk\src/keyboard.c:1576
  internal_condition_case at C:\emacs\trunk\src/eval.c:1192
  command_loop_2 at C:\emacs\trunk\src/keyboard.c:1163
  internal_catch at C:\emacs\trunk\src/eval.c:963
  command_loop at C:\emacs\trunk\src/keyboard.c:1134
  recursive_edit_1 at C:\emacs\trunk\src/keyboard.c:774
  read_minibuf at C:\emacs\trunk\src/minibuf.c:678
  Fread_from_minibuffer at C:\emacs\trunk\src/minibuf.c:980
  Ffuncall at C:\emacs\trunk\src/eval.c:2697
  exec_byte_code at C:\emacs\trunk\src/bytecode.c:899
  funcall_lambda at C:\emacs\trunk\src/eval.c:2903
  Ffuncall at C:\emacs\trunk\src/eval.c:2720
  exec_byte_code at C:\emacs\trunk\src/bytecode.c:899
  funcall_lambda at C:\emacs\trunk\src/eval.c:2903
  Ffuncall at C:\emacs\trunk\src/eval.c:2720
  exec_byte_code at C:\emacs\trunk\src/bytecode.c:899
  Fbyte_code at C:\emacs\trunk\src/bytecode.c:474
  eval_sub at C:\emacs\trunk\src/eval.c:2042
  internal_catch at C:\emacs\trunk\src/eval.c:963
  exec_byte_code at C:\emacs\trunk\src/bytecode.c:1080
  funcall_lambda at C:\emacs\trunk\src/eval.c:2903
  Ffuncall at C:\emacs\trunk\src/eval.c:2720
  exec_byte_code at C:\emacs\trunk\src/bytecode.c:899
  funcall_lambda at C:\emacs\trunk\src/eval.c:2837
  Ffuncall at C:\emacs\trunk\src/eval.c:2720
  exec_byte_code at C:\emacs\trunk\src/bytecode.c:899
  Fbyte_code at C:\emacs\trunk\src/bytecode.c:474
  eval_sub at C:\emacs\trunk\src/eval.c:2042
  internal_catch at C:\emacs\trunk\src/eval.c:963
  exec_byte_code at C:\emacs\trunk\src/bytecode.c:1080
  Fbyte_code at C:\emacs\trunk\src/bytecode.c:474