freetype-devel
[Top][All Lists]
Advanced

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

Re: patch for ttload.c


From: Tom Kacvinsky
Subject: Re: patch for ttload.c
Date: Sun, 2 Jul 2000 17:58:58 -0400 (EDT)

In function FT_Read_Fields, we should have:

      case ft_frame_off3_le:
      case ft_frame_uoff3_le:  /* read a 3-byte little-endian long */
        {
          char* p;

          value = 0;
          p     = stream->cursor;

          if ( p + 2 < stream->limit )
          {
            value =   (FT_ULong)p[0]         |
                    ( (FT_ULong)p[1] << 8  ) |
                    ( (FT_ULong)p[2] << 16 );
            stream->cursor += 3;
          }
          sign_shift = 8;
          break;
        }

Instead of:

      case ft_frame_off3_le:
      case ft_frame_uoff3_le:  /* read a 3-byte little-endian long */
        {
          char* p;

          value = 0;
          p     = stream->cursor;

          if ( p + 3 < stream->limit )
          {
            value =   (FT_ULong)p[0]         |
                    ( (FT_ULong)p[1] << 8  ) |
                    ( (FT_ULong)p[2] << 16 ) |
                    ( (FT_ULong)p[3] << 24 );
            stream->cursor += 4;
          }
          sign_shift = 8;
          break;
        }





reply via email to

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