summaryrefslogtreecommitdiff
path: root/pango
diff options
context:
space:
mode:
authorMatthias Clasen <mclasen@redhat.com>2021-01-21 19:51:02 +0000
committerMatthias Clasen <mclasen@redhat.com>2021-01-21 19:51:02 +0000
commit30748213af2bdc373aab076927a7c73ec314b776 (patch)
tree12e56ca20c02de9ab40a3dc39163b1f5016f1127 /pango
parent59074f13f87f09f493b0534da302f915a3f67a8f (diff)
parent0a816b491b3eac8ca7d285857bd57efa3658d7ae (diff)
downloadpango-30748213af2bdc373aab076927a7c73ec314b776.tar.gz
Merge branch 'fix' into 'master'
Fix the length checking Closes #526 See merge request GNOME/pango!273
Diffstat (limited to 'pango')
-rw-r--r--pango/pango-context.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/pango/pango-context.c b/pango/pango-context.c
index 1fcdf366..a3d7e6c4 100644
--- a/pango/pango-context.c
+++ b/pango/pango-context.c
@@ -1572,7 +1572,7 @@ pango_itemize_with_base_dir (PangoContext *context,
g_return_val_if_fail (length >= 0, NULL);
g_return_val_if_fail (length == 0 || text != NULL, NULL);
- if (length == 0 || g_utf8_strlen (text, length) == 0)
+ if (length == 0 || g_utf8_strlen (text + start_index, length) == 0)
return NULL;
itemize_state_init (&state, context, text, base_dir, start_index, length,