Common: detect bad WFN font format

This prevents memory corruption if the font format is broken.