Subject: bug#51007: 27.2; emacs hangs when using window-toggle-side-windows

From: Eli Zaretskii <[email-masked]>
Date: Sun, 10 Oct 2021 13:55:53 +0300

> Cc: [email-masked], [email-masked]
> From: martin rudalics <[email-masked]>
> Date: Sun, 10 Oct 2021 10:58:12 +0200
> 
>  > What are the actual values of the data in this assertion:
>  >
>  > 	      eassert (r->glyphs[TEXT_AREA] >= fr->glyphs[TEXT_AREA]
>  > 		       && r->glyphs[LAST_AREA] <= fr->glyphs[LAST_AREA]);
> 
> How would I do that?  These are structures like
> 
> (gdb) p r->glyphs[TEXT_AREA]
> $1 = (struct glyph *) 0xe2df90
> (gdb) p fr->glyphs[TEXT_AREA]
> $2 = (struct glyph *) 0xe36690

These are the values I meant: the above shows the window's glyph
matrix and the frame's glyph matrix are unrelated.  Not sure how that
happened; perhaps one of them was recently reallocated?

> BTW, the bug is easily reproducible using the following scenario: With
> a master emacs -Q in an -nw session I evaluate

So you want me to debug it?

> I suppose 'delete-other-windows-internal' mangles the window dimensions
> but the scenarios work on GUI frames and pass all internal checks here
> so it will take me some time to sort this out ...

On GUI frames, the window's glyph matrices are allocated separately
and there's no frame glyph matrix to begin with.