Commit 52a6194f authored by Dmitry Antipov's avatar Dmitry Antipov
Browse files

* font.c (font_make_object): Avoid dangling pointer which may

crash GC (Bug#17771).
parent bc2fb4fd
2014-06-19 Dmitry Antipov <dmantipov@yandex.ru>
* font.c (font_make_object): Avoid dangling pointer which may
crash GC (Bug#17771).
2014-06-18 Eli Zaretskii <eliz@gnu.org> 2014-06-18 Eli Zaretskii <eliz@gnu.org>
* image.c [5 < GIFLIB_MAJOR + (1 <= GIFLIB_MINOR)]: Declare the * image.c [5 < GIFLIB_MAJOR + (1 <= GIFLIB_MINOR)]: Declare the
......
...@@ -207,6 +207,9 @@ font_make_object (int size, Lisp_Object entity, int pixelsize) ...@@ -207,6 +207,9 @@ font_make_object (int size, Lisp_Object entity, int pixelsize)
= (struct font *) allocate_pseudovector (size, FONT_OBJECT_MAX, PVEC_FONT); = (struct font *) allocate_pseudovector (size, FONT_OBJECT_MAX, PVEC_FONT);
int i; int i;
/* GC can happen before the driver is set up,
so avoid dangling pointer here (Bug#17771). */
font->driver = NULL;
XSETFONT (font_object, font); XSETFONT (font_object, font);
if (! NILP (entity)) if (! NILP (entity))
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment