summaryrefslogtreecommitdiff
path: root/src/fontset.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/fontset.c')
-rw-r--r--src/fontset.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/fontset.c b/src/fontset.c
index 3eb835401f2..bd9f719423a 100644
--- a/src/fontset.c
+++ b/src/fontset.c
@@ -547,8 +547,11 @@ fontset_find_font (fontset, c, face, id, fallback)
for (i = 0; i < ASIZE (vec); i++)
{
Lisp_Object rfont_def = AREF (vec, i);
- Lisp_Object repertory
- = FONT_DEF_REPERTORY (RFONT_DEF_FONT_DEF (rfont_def));
+ Lisp_Object repertory;
+
+ if (NILP (rfont_def))
+ break;
+ repertory = FONT_DEF_REPERTORY (RFONT_DEF_FONT_DEF (rfont_def));
if (XINT (repertory) == id)
{