Skip to content

Improve cff index reading code

In a recent MR 1, Adrian Johnson writes:

For additional safety you could change the unsigned long to size_t since long is 32-bits on Win64. The CFF spec says the offset size used in decode_index_offset must be between 1 and 4 so you could range check that to avoid overflowing the offset.

This commit implements exactly that.

Signed-off-by: Uli Schlachter psychon@znc.in

Merge request reports