[NTG-pdftex] [pdftex-Bugs][2082] font_dim[FONTNAME_CODE] not initialized (writefont.c)

pdftex-bugs at sarovar.org pdftex-bugs at sarovar.org
Wed Nov 26 14:49:29 CET 2008

Bugs item #2082, was opened at 2008-08-12 15:45
>Status: Closed
Priority: 3
Submitted By: The Thanh Han (hanthethanh)
Assigned to: The Thanh Han (hanthethanh)
Summary: font_dim[FONTNAME_CODE] not initialized (writefont.c) 
Category: Fonts
Group: None
Resolution: Accepted

Initial Comment:
I found an issue with writefont.c: when a new en_entry is created, the value of
font_dim[FONTNAME_CODE] is not initialized. For T1 fonts this is not a problem
since all T1 fonts have fontname, but for TT fonts some weird fonts might not
have [I ran into this problem during a test on some large TT fonts with

Here is the suggested patch:

Index: source/src/texk/web2c/pdftexdir/writefont.c
--- source/src/texk/web2c/pdftexdir/writefont.c (revision 508)
+++ source/src/texk/web2c/pdftexdir/writefont.c (revision 509)
@@ -81,7 +81,7 @@
     fd->fn_objnum = 0;
     fd->all_glyphs = false;
     fd->write_ttf_glyph_names = false;
-    for (i = 0; i < INT_KEYS_NUM; i++) {
+    for (i = 0; i < FONT_KEYS_NUM; i++) {
         fd->font_dim[i].val = 0;
         fd->font_dim[i].set = false;


You can respond by visiting: 

More information about the ntg-pdftex mailing list