all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: martin rudalics <rudalics@gmx.at>
Cc: 60096@debbugs.gnu.org, juri@linkov.net
Subject: bug#60096: 29.0.60; Crash in format_mode_line_unwind_data
Date: Sat, 17 Dec 2022 12:00:47 +0200	[thread overview]
Message-ID: <838rj6ic34.fsf@gnu.org> (raw)
In-Reply-To: <325aaa94-74fa-cf94-b66c-b87c69ebe386@gmx.at> (message from martin rudalics on Sat, 17 Dec 2022 10:17:00 +0100)

> Date: Sat, 17 Dec 2022 10:17:00 +0100
> Cc: juri@linkov.net, 60096@debbugs.gnu.org
> From: martin rudalics <rudalics@gmx.at>
> 
>  > Basically, set-window-configuration was called in a situation where it
>  > has only one valid buffer to play with, which is tough for its logic
>  > and the various other functions it invokes.  The result was a bunch of
>  > bad windows with nil as their buffer.
> 
> If a live window has nil as its buffer, next redisplay will reliably
> crash Emacs anyway.  So this
> 
>        /* We may have deleted windows above.  Then again, maybe we
> 	 haven't: the functions we call to maybe delete windows can
> 	 decide a window cannot be deleted.  Force recalculation of
> 	 Vwindow_list next time it is needed, to make sure stale
> 	 windows with no buffers don't escape into the wild, which
> 	 will cause crashes elsewhere.  */
>        Vwindow_list = Qnil;
> 
> should not be needed.

It is needed in this case because it forces redisplay to recompute the
window list (in propagate_buffer_redisplay, if not earlier).  If the
above is not done, Vwindow_list will be reused, and the problematic
(bogus?) windows in it _will_ cause a crash.

> The earlier call
> 
>        delete_all_child_windows (FRAME_ROOT_WINDOW (f));
> 
> should have reliably reset Vwindow_list to nil.

AFAIR, the code which runs after that call recalculated Vwindow_list,
adding to it those windows with no buffer.  You should be able to see
that by running the simple recipe posted by Juri at the beginning of
this bug report.

What about the other parts of the changeset I installed -- do they
look okay to you? any comments?





  reply	other threads:[~2022-12-17 10:00 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-12-15 17:04 bug#60096: 29.0.60; Crash in format_mode_line_unwind_data Juri Linkov
2022-12-15 21:42 ` Eli Zaretskii
2022-12-16  7:31   ` Juri Linkov
2022-12-16 11:46     ` Eli Zaretskii
2022-12-16 14:39       ` Eli Zaretskii
2022-12-16 15:03         ` Eli Zaretskii
2022-12-17  9:17           ` martin rudalics
2022-12-17 10:00             ` Eli Zaretskii [this message]
2022-12-17 10:53               ` Eli Zaretskii
2022-12-17 15:26               ` martin rudalics
2022-12-17 15:59                 ` Eli Zaretskii
2022-12-17 17:05                   ` martin rudalics
2022-12-17 17:52                     ` Eli Zaretskii
2022-12-18  9:18                       ` martin rudalics
2022-12-18 11:40                         ` Eli Zaretskii
2022-12-17 17:23           ` Juri Linkov
2022-12-17 17:59             ` Eli Zaretskii

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

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

  git send-email \
    --in-reply-to=838rj6ic34.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=60096@debbugs.gnu.org \
    --cc=juri@linkov.net \
    --cc=rudalics@gmx.at \
    /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 external index

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

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.