diff --git a/src/pshinter/pshalgo.c b/src/pshinter/pshalgo.c index ca3070232..45ec06154 100644 --- a/src/pshinter/pshalgo.c +++ b/src/pshinter/pshalgo.c @@ -1299,7 +1299,8 @@ PSH_Point point, before, after; - if ( glyph->contours[n].count == 0 ) + /* we need at least 3 points to create an extremum */ + if ( glyph->contours[n].count < 3 ) continue; point = first; @@ -1309,7 +1310,7 @@ { before = before->prev; if ( before == first ) - goto Skip; + goto Next; } while ( before->org_u == point->org_u );