diff options
author | Matthias Clasen <mclasen@redhat.com> | 2019-07-17 13:11:06 -0400 |
---|---|---|
committer | Matthias Clasen <mclasen@redhat.com> | 2019-07-17 13:11:06 -0400 |
commit | 989d86820f72e532acd9f75dc95c1ec00b47bce2 (patch) | |
tree | fc79c63f951506f9edf914c08b8e4e1342014eb0 /pango/pango-item.c | |
parent | c3e05ce8759d9858ec14c4ade2f5987b90b42c6b (diff) | |
download | pango-989d86820f72e532acd9f75dc95c1ec00b47bce2.tar.gz |
Fix no-break attribute filtering
pango_attribute_equal does not compare ranges. Oops.
Diffstat (limited to 'pango/pango-item.c')
-rw-r--r-- | pango/pango-item.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/pango/pango-item.c b/pango/pango-item.c index d2d45aab..b43ed3a5 100644 --- a/pango/pango-item.c +++ b/pango/pango-item.c @@ -157,7 +157,11 @@ pango_item_split (PangoItem *orig, static int compare_attr (gconstpointer p1, gconstpointer p2) { - if (pango_attribute_equal ((PangoAttribute *)p1, (PangoAttribute *)p2)) + const PangoAttribute *a1 = p1; + const PangoAttribute *a2 = p2; + if (pango_attribute_equal (a1, a2) && + a1->start_index == a2->start_index && + a1->end_index == a2->end_index) return 0; return 1; |