[pshinter] Fix thinko. * src/pshinter/pshalgo.c (psh_glyph_find_strong_points): Correctly check `count'. Bug introduced two commits earlier.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40
diff --git a/ChangeLog b/ChangeLog
index e832dbf..c06a10e 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,13 @@
2015-02-22 Werner Lemberg <wl@gnu.org>
+ [pshinter] Fix thinko.
+
+ * src/pshinter/pshalgo.c (psh_glyph_find_strong_points): Correctly
+ check `count'.
+ Bug introduced two commits earlier.
+
+2015-02-22 Werner Lemberg <wl@gnu.org>
+
[raster] Signedness fixes.
* src/raster/ftraster.c, src/raster/ftrend1.c: Apply.
diff --git a/src/pshinter/pshalgo.c b/src/pshinter/pshalgo.c
index d36600e..d04d120 100644
--- a/src/pshinter/pshalgo.c
+++ b/src/pshinter/pshalgo.c
@@ -1696,14 +1696,12 @@
mask++;
for ( ; num_masks > 1; num_masks--, mask++ )
{
- FT_UInt next;
- FT_UInt count;
+ FT_UInt next = FT_MIN( mask->end_point, glyph->num_points );
- next = FT_MIN( mask->end_point, glyph->num_points );
- count = next - first;
- if ( count > 0 )
+ if ( next > first )
{
+ FT_UInt count = next - first;
PSH_Point point = glyph->points + first;