GNU bug report logs - #75056
31.0.50; tty-child-frames with server / multiple clients possible hangs

Previous Next

Package: emacs;

Reported by: Len Trigg <lenbok <at> gmail.com>

Date: Tue, 24 Dec 2024 05:44:02 UTC

Severity: normal

Found in version 31.0.50

Full log


Message #221 received at 75056 <at> debbugs.gnu.org (full text, mbox):

From: martin rudalics <rudalics <at> gmx.at>
To: Gerd Möllmann <gerd.moellmann <at> gmail.com>
Cc: Eli Zaretskii <eliz <at> gnu.org>, lenbok <at> gmail.com, 75056 <at> debbugs.gnu.org
Subject: Re: bug#75056: 31.0.50; tty-child-frames with server / multiple
 clients possible hangs
Date: Mon, 27 Jan 2025 08:59:59 +0100
(4) As noted elsewhere, the documentation must be rewritten.

> Can't talk for w32, but I've removed the "obscuring" fromt the ttys
> because it plainly went against the rest with tty child frames.

You could have left it in to handle invisible top frames but maybe
that's really not needed any more.  Whatever you decide here, the
following issues must be resolved:

(1) Fframe_visible_p has this

  else if (is_tty_root_frame (f))
    return Qt;

where is_tty_root_frame is defined as

  return !FRAME_PARENT_FRAME (f) && is_tty_frame (f);

This is wrong because it will return t even if F has been explicitly
made invisible.

(2) do_switch_frame now has this

	  if (FRAMEP (top_frame))
	    {
	      struct frame *top = XFRAME (top_frame);
	      struct frame *old_root = root_frame (top);
	      if (old_root != new_root)
		SET_FRAME_VISIBLE (old_root, false);
	    }

This is wrong because it will set the visibility of the old top frame to
nil.  This will change the behavior of many functions that check the
visibility of frames, notably here in candidate_window_p in window.c

  else if (EQ (all_frames, Qvisible))
    {
      candidate_p = FRAME_VISIBLE_P (f)
	&& (FRAME_TERMINAL (XFRAME (w->frame))
	    == FRAME_TERMINAL (XFRAME (selected_frame)));

    }

where a window on the prior top frame will be no more considered as
eligible.

(3) I have not checked whether it's needed but I strongly suppose we now
need a frame_visible_invisible_hook for ttys too.

martin




This bug report was last modified 111 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.