unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: Roland Winkler <Roland.Winkler@physik.uni-erlangen.de>
Cc: 6177@debbugs.gnu.org
Subject: bug#6177: 23.2; emacs crashes when reverting a file
Date: Wed, 12 May 2010 21:13:00 +0300	[thread overview]
Message-ID: <83d3x1ouoj.fsf@gnu.org> (raw)
In-Reply-To: <19434.43397.585317.669911@regnitz.physics.niu.edu>

> Date: Wed, 12 May 2010 08:13:41 -0500
> From: "Roland Winkler" <Roland.Winkler@physik.uni-erlangen.de>
> Cc: 6177@debbugs.gnu.org
> 
> Any hints on what these crashes are possibly be related with
> according to the backtrace are greatly appreciated.

Let me try to give you some insights, by walking the call-stack
frames, telling what I see, and asking questions.

  #1  0x081deb85 in temp_set_point_both (buffer=0x98411c8, charpos=92, bytepos=92) at intervals.c:1950

This frame causes the crash here:

  if (charpos > BUF_ZV (buffer) || charpos < BUF_BEGV (buffer))
    abort ();

BUF_ZV and BUF_BEGV are, respectively (point-max) and (point-min) of
the buffer.  Since we see that charpos is 92, I'm guessing that the
first comparison is the culprit, i.e. (point-max) is less than or
equal to 92.

What do the following GDB commands display in frame #1?

  (gdb) print buffer->zv
  (gdb) print *buffer->text->beg@N

Here N is the value of buffer->zv displayed by the first command.

  #2  0x08091754 in redisplay_window (window=159032549, just_this_one_p=0) at xdisp.c:13940

This frame calls temp_set_point_both here:

  /* Restore current_buffer and value of point in it.  */
  TEMP_SET_PT_BOTH (CHARPOS (opoint), BYTEPOS (opoint));

opoint is initialized at the beginning of the function to the value of
point:

  SET_TEXT_POS (lpoint, PT, PT_BYTE);
  opoint = lpoint;

So it looks like the value of point that was valid before redisplaying
the window somehow became invalid during redisplaying it.  Hmm...
What kind of buffer is this?  Type these commands to find out:

  (gdb) print buffer->name
  (gdb) xstring

Also, what window are we redisplaying?  Type these commands:

  (gdb) print w->mini_p
  (gdb) xsymbol

TIA





  reply	other threads:[~2010-05-12 18:13 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-05-11 23:28 bug#6177: 23.2; emacs crashes when reverting a file Roland Winkler
2010-05-12  3:05 ` Eli Zaretskii
2010-05-12 13:13   ` Roland Winkler
2010-05-12 18:13     ` Eli Zaretskii [this message]
2010-05-12 21:13   ` Roland Winkler
2010-05-26  9:18 ` Geoff Gole
2010-05-26 15:01   ` Roland Winkler
2010-05-27 15:46     ` Chong Yidong
2010-06-04  6:29 ` Gilles Pion
2010-06-07  7:04   ` Glenn Morris
2010-06-04  7:44 ` Gilles Pion
2010-06-15 12:44 ` Gilles Pion
2010-06-15 13:32   ` Stefan Monnier
2010-06-15 19:45 ` Glenn Morris

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=83d3x1ouoj.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=6177@debbugs.gnu.org \
    --cc=Roland.Winkler@physik.uni-erlangen.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).