[pdftex] pdftex core dump when including certain pdf files

Karl Berry karl at freefriends.org
Sun Jul 17 00:33:29 CEST 2016

    -        fd = epdf_create_fontdescriptor(fontmap, stemV->getInt());
    +        fd = epdf_create_fontdescriptor(fontmap, zround(stemV->getNum()));

Ok.  StemV is the only parameter that is treated specially in this way.
(Thanh: why?  E.g., why nothing similar for StemH?  Just trying to
understand ...)

But then there are the other PDF font descriptor parameters to consider.
As Ross said, FontWeight, ItalicAngle, Ascent, Descent, Leading,
CapHeight, XHeight, StemH, AvgWidth, MaxWidth, MissingWidth are also all
"numbers" (float).

In ptexlib.h, struct fd_entry_ represents them (the ones it cares
about) with  intparm font_dim[FONT_KEYS_NUM];  if I'm reading the code
correctly.  It is not clear to me if that merely means they get
truncated at some point, or something worse happens.

Norbert, could you easily remake your modified font with floating-point
values for all the above and see if pdftex (ideally with or without
poppler) crashes, and/or if the result is reasonable?  And post the
modified font here.

If you're tied up for now, that's fine, of course.  One of us should get
to it eventually, though.

In principle, we should clearly represent them in floating-point or
fixed-point, not integers, but I can't say I'm enthused about spending
time on that.

--thanks, karl.

More information about the pdftex mailing list