GNU bug report logs - #37415
Asserting failure setting frame parameters to non-fixnum values in early-init.el

Previous Next

Package: emacs;

Reported by: Juanma Barranquero <lekktu <at> gmail.com>

Date: Sun, 15 Sep 2019 22:35:02 UTC

Severity: normal

Done: Eli Zaretskii <eliz <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


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

From: martin rudalics <rudalics <at> gmx.at>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: lekktu <at> gmail.com, 37415 <at> debbugs.gnu.org
Subject: Re: bug#37415: Asserting failure setting frame parameters to
 non-fixnum values in early-init.el
Date: Sun, 22 Sep 2019 19:54:00 +0200
> No, I don't think using x_get_arg is wrong, because we still want to
> determine whether to use CW_USEDEFAULT.

Hmm ...

> We cannot do this unless f->size_hint_flags are set so as to tell
> w32_createwindow to use f->top_pos and/or f->left_pos.  Otherwise, we
> should put CW_USEDEFAULT in coords[].  IOW, how about the below?
[...]
> +  if (!(f->size_hint_flags & USPosition || f->size_hint_flags & PPosition))
> +    {
> +      /* When called with RES_TYPE_NUMBER, and there's no 'top' or
> +	 'left' parameters in the frame's parameter alist,
> +	 gui_display_get_arg will return zero for anything that is
> +	 neither a number nor Qunbound.  If frame parameter alist does
> +	 have 'left' or 'top', they are interpreted by
> +	 gui_figure_window_size, which was already called, and which
> +	 sets f->size_hint_flags.  */

So you mean when size hints are not set, we are sure that
gui_display_get_arg does not find anything in 'default-frame-alist'
(ignoring, BTW 'initial-frame-alist') and finds a number here.  This
looks a bit fragile to me.  Isn't the fact that left/top are unbound
sufficient that we should use CW_USEDEFAULT and f->left_pos/f->top_pos
otherwise.  Or don't you want to call gui_display_get_arg twice?

martin




This bug report was last modified 5 years and 246 days ago.

Previous Next


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