Make sure feature values don't leak out of their mask
authorBehdad Esfahbod <behdad@behdad.org>
Wed, 13 Oct 2010 19:36:38 +0000 (15:36 -0400)
committerBehdad Esfahbod <behdad@behdad.org>
Wed, 13 Oct 2010 19:36:38 +0000 (15:36 -0400)
src/hb-buffer.cc

index 800a34d..d6e38e9 100644 (file)
@@ -476,6 +476,7 @@ _hb_buffer_add_masks (hb_buffer_t *buffer,
                      unsigned int cluster_end)
 {
   hb_mask_t not_mask = ~mask;
+  value &= mask;
 
   if (cluster_start == 0 && cluster_end == (unsigned int)-1) {
     unsigned int count = buffer->len;