diff options
author | Behdad Esfahbod <behdad@behdad.org> | 2009-09-21 13:43:54 -0400 |
---|---|---|
committer | Behdad Esfahbod <behdad@behdad.org> | 2009-09-21 13:43:54 -0400 |
commit | d50615c838ef7b448021dacbe4daa49aa26ea388 (patch) | |
tree | 607bf44e321fed1262f201fa56158e7d12263f28 | |
parent | 73f94ec879476f52adac105570f4cebe5bd02c0c (diff) | |
download | pango-d50615c838ef7b448021dacbe4daa49aa26ea388.tar.gz |
[HB] Fix apply_lookup() loop
Part of Bug 595539 - Regressions in rendering certain Thai sequences with
OpenType font
-rw-r--r-- | pango/opentype/hb-ot-layout-gsubgpos-private.hh | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/pango/opentype/hb-ot-layout-gsubgpos-private.hh b/pango/opentype/hb-ot-layout-gsubgpos-private.hh index e96e4e39..fd9c7839 100644 --- a/pango/opentype/hb-ot-layout-gsubgpos-private.hh +++ b/pango/opentype/hb-ot-layout-gsubgpos-private.hh @@ -219,7 +219,7 @@ static inline bool apply_lookup (APPLY_ARG_DEF, /* TODO We don't support lookupRecord arrays that are not increasing: * Should be easy for in_place ones at least. */ - for (unsigned int i = 0; i < count; i++) + for (unsigned int i = 0; i < count; /* NOP */) { while (_hb_ot_layout_skip_mark (context->face, IN_CURINFO (), lookup_flag, NULL)) { @@ -238,6 +238,7 @@ static inline bool apply_lookup (APPLY_ARG_DEF, lookupRecord++; lookupCount--; + /* Err, this is wrong if the lookup jumped over some glyphs */ i += buffer->in_pos - old_pos; if (HB_UNLIKELY (buffer->in_pos == end)) return true; |