Commit 0971735dce99e98fc2b79be764494b34d0f152a1

David Turner 2006-06-04T14:33:08

* src/pfr/pfrobjs.c (pfr_face_init): fix the computation of 'face->num_glyphs' which missed the last glyph, due to the offset-by-1 computation, since the PFR format doesn't guarantee that glyph index 0 corresponds to the "missing glyph" should fix bug #16668

diff --git a/ChangeLog b/ChangeLog
index 1ed6676..1f59d11 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,13 @@
+2006-06-04  David Turner  <david@freetype.org>
+
+  * src/pfr/pfrobjs.c (pfr_face_init): fix the computation
+  of 'face->num_glyphs' which missed the last glyph, due to
+  the offset-by-1 computation, since the PFR format doesn't
+  guarantee that glyph index 0 corresponds to the "missing
+  glyph"
+
+  should fix bug #16668
+
 2006-05-25  Werner Lemberg  <wl@gnu.org>
 
 	* builds/unix/unix-cc.in (LINK_LIBRARY): Don't comment out
diff --git a/src/pfr/pfrobjs.c b/src/pfr/pfrobjs.c
index 6c0ce90..b566d73 100644
--- a/src/pfr/pfrobjs.c
+++ b/src/pfr/pfrobjs.c
@@ -128,7 +128,7 @@
 
 
       pfrface->face_index = face_index;
-      pfrface->num_glyphs = phy_font->num_chars;
+      pfrface->num_glyphs = phy_font->num_chars + 1;
       pfrface->face_flags = FT_FACE_FLAG_SCALABLE;
 
       if ( (phy_font->flags & PFR_PHY_PROPORTIONAL) == 0 )