freetype-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [ft-devel] Patch to allow '\0' in sfnt name table entries


From: Alexei Podtelezhnikov
Subject: Re: [ft-devel] Patch to allow '\0' in sfnt name table entries
Date: Wed, 14 Mar 2012 08:53:28 -0400

On Wed, Mar 14, 2012 at 8:17 AM, Huw Davies <address@hidden> wrote:
> On Wed, Mar 14, 2012 at 07:58:55AM -0400, Alexei Podtelezhnikov wrote:
>> On Wed, Mar 14, 2012 at 7:26 AM, Huw Davies <address@hidden> wrote:
>> > The attached patch fixes a problem with fonts that include a trailing
>> > '\0' in name table entries.  Currently the font name would have a
>> > question mark appended to it.
>>
>> Why would the name contain \0?
>> Is this because entry->stringLength is larger than it should be?
>> May this bug be somewhere else?
>
> Yes, the name table entries of these fonts include a trailing '\0' and
> the character counts include that '\0'.

Then I would prefer

if (code == 0)
   break;

if ( code < 32 || code > 127 )
   code = '?';



reply via email to

[Prev in Thread] Current Thread [Next in Thread]