diff options
author | Eli Zaretskii <eliz@gnu.org> | 2017-12-10 10:42:34 +0200 |
---|---|---|
committer | Eli Zaretskii <eliz@gnu.org> | 2017-12-10 10:42:34 +0200 |
commit | ad491c80e4b0cfc5be049eb397aa535ed74eade8 (patch) | |
tree | 73d58f016001dd134b9be7d8ec06a789ab35942b /src | |
parent | c73d2cdfd738186a3b4e44e3fcec4a9f10b9b644 (diff) | |
download | emacs-ad491c80e4b0cfc5be049eb397aa535ed74eade8.tar.gz |
Avoid crashes in 'font-at' after 'set-fontset-font'
* src/fontset.c (free_realized_fontsets): Call
recompute_basic_faces, so that the basic faces are available to
any Lisp that calls this function, e.g. via set-fontset-font.
(Bug#29632)
Diffstat (limited to 'src')
-rw-r--r-- | src/fontset.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/fontset.c b/src/fontset.c index 35586ad5c7d..985800103d2 100644 --- a/src/fontset.c +++ b/src/fontset.c @@ -1325,6 +1325,10 @@ free_realized_fontsets (Lisp_Object base) if (CHAR_TABLE_P (this) && EQ (FONTSET_BASE (this), base)) { Fclear_face_cache (Qt); + /* This is in case some Lisp calls this function and then + proceeds with calling some other function, like font-at, + which needs the basic faces. */ + recompute_basic_faces (XFRAME (FONTSET_FRAME (this))); break; } } |