diff options
author | Kenichi Handa <handa@m17n.org> | 2008-01-14 01:33:28 +0000 |
---|---|---|
committer | Kenichi Handa <handa@m17n.org> | 2008-01-14 01:33:28 +0000 |
commit | 0a16d56798ff55e7ada300cc2dd0c17a4420f9ae (patch) | |
tree | 792635357c5a2d25434ce29a49d0cfab64ebd2c2 /src/font.c | |
parent | 432cfa542ebdc072be3fe798631bba3ab9647e27 (diff) | |
download | emacs-0a16d56798ff55e7ada300cc2dd0c17a4420f9ae.tar.gz |
*** empty log message ***
Diffstat (limited to 'src/font.c')
-rw-r--r-- | src/font.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/font.c b/src/font.c index 349862b6c2b..f9097d1f064 100644 --- a/src/font.c +++ b/src/font.c @@ -2699,7 +2699,7 @@ font_find_for_lface (f, lface, spec, c) if (result > 0) return AREF (entities, i); - if (result <= 0) + if (result == 0) continue; font_object = font_open_for_lface (f, AREF (entities, i), lface, spec); if (NILP (font_object)) @@ -3577,9 +3577,12 @@ FONT-OBJECT. */) for (i = 0; i < len; i++) { Lisp_Object g = LGSTRING_GLYPH (gstring, i); - unsigned code = LGLYPH_CODE (g); + unsigned code; struct font_metrics metrics; + if (NILP (g)) + break; + code = LGLYPH_CODE (g); if (font->driver->text_extents (font, &code, 1, &metrics) == 0) { Lisp_Object gstr = Ffont_make_gstring (font_object, |