[HarfBuzz] harfbuzz: Branch 'master'

Behdad Esfahbod behdad at kemper.freedesktop.org
Mon Apr 4 21:35:35 UTC 2016


 src/hb-open-type-private.hh |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 6dd80faf0dcb3e8a8915c3a25da44e2a67cb0cd8
Author: Behdad Esfahbod <behdad at behdad.org>
Date:   Mon Apr 4 14:34:25 2016 -0700

    Fix FixedVersion::to_int()
    
    Ouch.  Had broken it in 9a13ed453ef96822a47d6e6f58332b87f38d5c59
    
    Fixes https://github.com/behdad/harfbuzz/issues/238
    Will add test soon.

diff --git a/src/hb-open-type-private.hh b/src/hb-open-type-private.hh
index 0754ef0..80ad687 100644
--- a/src/hb-open-type-private.hh
+++ b/src/hb-open-type-private.hh
@@ -751,7 +751,7 @@ struct CheckSum : ULONG
 template <typename FixedType=USHORT>
 struct FixedVersion
 {
-  inline uint32_t to_int (void) const { return (major << sizeof(FixedType)) + minor; }
+  inline uint32_t to_int (void) const { return (major << (sizeof(FixedType) * 8)) + minor; }
 
   inline bool sanitize (hb_sanitize_context_t *c) const
   {


More information about the HarfBuzz mailing list