GNU bug report logs - #23386
Segfault when messing with font-backend

Previous Next

Package: emacs;

Reported by: Stefan Monnier <monnier <at> IRO.UMontreal.CA>

Date: Wed, 27 Apr 2016 13:14:01 UTC

Severity: normal

Tags: confirmed

Merged with 35803, 36835, 39865

Found in versions 25.0.95, 28.0.50, 25.0.50, 24.1, 24.5, 26.2, 27.0.50

Fixed in version 27.1

Done: Robert Pluim <rpluim <at> gmail.com>

Bug is archived. No further changes may be made.

Full log


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

From: Eli Zaretskii <eliz <at> gnu.org>
To: Dmitry Antipov <dmantipov <at> yandex.ru>
Cc: 23386 <at> debbugs.gnu.org, npostavs <at> users.sourceforge.net
Subject: Re: bug#23386: Segfault when messing with font-backend
Date: Tue, 12 Jul 2016 20:45:30 +0300
> Cc: 23386 <at> debbugs.gnu.org
> From: Dmitry Antipov <dmantipov <at> yandex.ru>
> Date: Tue, 12 Jul 2016 18:20:41 +0300
> 
> > But it doesn't do what the user asked for.
> >
> > I don't see why it would be meaningless to evict a backend and start
> > using another one, if all it takes is re-open a bunch of fonts.
> 
> OK, the following patch basically works for me (not tested too much, BTW).

Thanks.

> --- a/src/frame.c
> +++ b/src/frame.c
> @@ -3712,7 +3712,11 @@ x_set_font_backend (struct frame *f, Lisp_Object new_value, Lisp_Object old_valu
>      return;
>  
>    if (FRAME_FONT (f))
> -    free_all_realized_faces (Qnil);
> +    {
> +      Lisp_Object frame;
> +      XSETFRAME (frame, f);
> +      free_all_realized_faces (frame);
> +    }

Since free_all_realized_faces with a nil argument will free faces on
all frames, can you tell why this hunk was needed?




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

Previous Next


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