From b46c7faa9c77e288d16869b9ac609524e0f89468 Mon Sep 17 00:00:00 2001 From: Behdad Esfahbod Date: Fri, 13 May 2022 14:02:54 -0600 Subject: [PATCH] [cff] Check buf_len, not buf Ouch! --- src/hb-ot-cff1-table.hh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/hb-ot-cff1-table.hh b/src/hb-ot-cff1-table.hh index 012aa1374..2f2a27888 100644 --- a/src/hb-ot-cff1-table.hh +++ b/src/hb-ot-cff1-table.hh @@ -1306,7 +1306,7 @@ struct cff1 bool get_glyph_name (hb_codepoint_t glyph, char *buf, unsigned int buf_len) const { - if (!buf) return true; + if (!buf_len) return true; if (unlikely (!is_valid ())) return false; if (is_CID()) return false; hb_codepoint_t sid = glyph_to_sid (glyph);