summaryrefslogtreecommitdiff
path: root/pango/pango-context.c
diff options
context:
space:
mode:
Diffstat (limited to 'pango/pango-context.c')
-rw-r--r--pango/pango-context.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/pango/pango-context.c b/pango/pango-context.c
index 49db52a9..0e3fb1e5 100644
--- a/pango/pango-context.c
+++ b/pango/pango-context.c
@@ -1310,7 +1310,7 @@ update_metrics_from_items (PangoFontMetrics *metrics,
PangoItem *item = l->data;
PangoFont *font = item->analysis.font;
- if (g_hash_table_lookup (fonts_seen, font) == NULL)
+ if (font != NULL && g_hash_table_lookup (fonts_seen, font) == NULL)
{
PangoFontMetrics *raw_metrics = pango_font_get_metrics (font, language);
g_hash_table_insert (fonts_seen, font, font);