diff options
-rw-r--r-- | ChangeLog | 5 | ||||
-rw-r--r-- | ChangeLog.pre-1-10 | 5 | ||||
-rw-r--r-- | ChangeLog.pre-1-4 | 5 | ||||
-rw-r--r-- | ChangeLog.pre-1-6 | 5 | ||||
-rw-r--r-- | ChangeLog.pre-1-8 | 5 | ||||
-rw-r--r-- | modules/hangul/hangul-fc.c | 28 | ||||
-rw-r--r-- | modules/hangul/hangul-x.c | 26 |
7 files changed, 54 insertions, 25 deletions
@@ -1,3 +1,8 @@ +Tue Apr 15 03:54:01 2003 Owen Taylor <otaylor@redhat.com> + + * modules/hangul/hangul-{x,fc}.c: Fix out-of-bounds read + where the value wasn't actually used. (#106744, Morten Welinder) + Tue Apr 15 03:47:37 2003 Owen Taylor <otaylor@redhat.com> * pango/pango-attributes.c (pango_attr_iterator_next): Return diff --git a/ChangeLog.pre-1-10 b/ChangeLog.pre-1-10 index 0a809a4b..08ded4f8 100644 --- a/ChangeLog.pre-1-10 +++ b/ChangeLog.pre-1-10 @@ -1,3 +1,8 @@ +Tue Apr 15 03:54:01 2003 Owen Taylor <otaylor@redhat.com> + + * modules/hangul/hangul-{x,fc}.c: Fix out-of-bounds read + where the value wasn't actually used. (#106744, Morten Welinder) + Tue Apr 15 03:47:37 2003 Owen Taylor <otaylor@redhat.com> * pango/pango-attributes.c (pango_attr_iterator_next): Return diff --git a/ChangeLog.pre-1-4 b/ChangeLog.pre-1-4 index 0a809a4b..08ded4f8 100644 --- a/ChangeLog.pre-1-4 +++ b/ChangeLog.pre-1-4 @@ -1,3 +1,8 @@ +Tue Apr 15 03:54:01 2003 Owen Taylor <otaylor@redhat.com> + + * modules/hangul/hangul-{x,fc}.c: Fix out-of-bounds read + where the value wasn't actually used. (#106744, Morten Welinder) + Tue Apr 15 03:47:37 2003 Owen Taylor <otaylor@redhat.com> * pango/pango-attributes.c (pango_attr_iterator_next): Return diff --git a/ChangeLog.pre-1-6 b/ChangeLog.pre-1-6 index 0a809a4b..08ded4f8 100644 --- a/ChangeLog.pre-1-6 +++ b/ChangeLog.pre-1-6 @@ -1,3 +1,8 @@ +Tue Apr 15 03:54:01 2003 Owen Taylor <otaylor@redhat.com> + + * modules/hangul/hangul-{x,fc}.c: Fix out-of-bounds read + where the value wasn't actually used. (#106744, Morten Welinder) + Tue Apr 15 03:47:37 2003 Owen Taylor <otaylor@redhat.com> * pango/pango-attributes.c (pango_attr_iterator_next): Return diff --git a/ChangeLog.pre-1-8 b/ChangeLog.pre-1-8 index 0a809a4b..08ded4f8 100644 --- a/ChangeLog.pre-1-8 +++ b/ChangeLog.pre-1-8 @@ -1,3 +1,8 @@ +Tue Apr 15 03:54:01 2003 Owen Taylor <otaylor@redhat.com> + + * modules/hangul/hangul-{x,fc}.c: Fix out-of-bounds read + where the value wasn't actually used. (#106744, Morten Welinder) + Tue Apr 15 03:47:37 2003 Owen Taylor <otaylor@redhat.com> * pango/pango-attributes.c (pango_attr_iterator_next): Return diff --git a/modules/hangul/hangul-fc.c b/modules/hangul/hangul-fc.c index 7300f897..0008ba08 100644 --- a/modules/hangul/hangul-fc.c +++ b/modules/hangul/hangul-fc.c @@ -303,26 +303,28 @@ hangul_engine_shape (PangoFont *font, for (i = 0; i < n_chars; i++) { - gunichar prev = jamos[n_jamos - 1]; gunichar wc; wc = g_utf8_get_char (p); /* Check syllable boundaries. */ - if (n_jamos && - ((!IS_L (prev) && IS_S (wc)) || - (IS_T (prev) && IS_L (wc)) || - (IS_V (prev) && IS_L (wc)) || - (IS_T (prev) && IS_V (wc)) || - IS_M(prev))) + if (n_jamos) { - /* Draw a syllable. */ - render_syllable (font, jamos, n_jamos, glyphs, - &n_glyphs, start - text); - n_jamos = 0; - start = p; + gunichar prev = jamos[n_jamos - 1]; + if ((!IS_L (prev) && IS_S (wc)) || + (IS_T (prev) && IS_L (wc)) || + (IS_V (prev) && IS_L (wc)) || + (IS_T (prev) && IS_V (wc)) || + IS_M(prev)) + { + /* Draw a syllable. */ + render_syllable (font, jamos, n_jamos, glyphs, + &n_glyphs, start - text); + n_jamos = 0; + start = p; + } } - + if (n_jamos == max_jamos) { max_jamos += 3; /* at most 3 for each syllable code (L+V+T) */ diff --git a/modules/hangul/hangul-x.c b/modules/hangul/hangul-x.c index 3ec4aa7e..72bbc655 100644 --- a/modules/hangul/hangul-x.c +++ b/modules/hangul/hangul-x.c @@ -739,24 +739,26 @@ hangul_engine_shape (PangoFont *font, for (i = 0; i < n_chars; i++) { - gunichar prev = jamos[n_jamos - 1]; gunichar wc; wc = g_utf8_get_char (p); /* Check syllable boundaries. */ - if (n_jamos && - ((!IS_L (prev) && IS_S (wc)) || - (IS_T (prev) && IS_L (wc)) || - (IS_V (prev) && IS_L (wc)) || - (IS_T (prev) && IS_V (wc)))) + if (n_jamos) { - /* Draw a syllable. */ - - (*render_func) (font, subfont, jamos, n_jamos, - glyphs, &n_glyphs, start - text); - n_jamos = 0; - start = p; + gunichar prev = jamos[n_jamos - 1]; + if ((!IS_L (prev) && IS_S (wc)) || + (IS_T (prev) && IS_L (wc)) || + (IS_V (prev) && IS_L (wc)) || + (IS_T (prev) && IS_V (wc))) + { + /* Draw a syllable. */ + + (*render_func) (font, subfont, jamos, n_jamos, + glyphs, &n_glyphs, start - text); + n_jamos = 0; + start = p; + } } if (n_jamos == max_jamos) |