From a12f346425774932f4fc18a4ad9dc75288ba17d5 Mon Sep 17 00:00:00 2001 From: Hermet Park Date: Thu, 13 Aug 2020 19:00:09 +0900 Subject: [PATCH] sw_engine: remove unnecessary assert() call Change-Id: I7c665bab4ef867f912ea738480e6d9b2b63e014e --- src/lib/sw_engine/tvgSwStroke.cpp | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/src/lib/sw_engine/tvgSwStroke.cpp b/src/lib/sw_engine/tvgSwStroke.cpp index d8902da..edba638 100644 --- a/src/lib/sw_engine/tvgSwStroke.cpp +++ b/src/lib/sw_engine/tvgSwStroke.cpp @@ -880,7 +880,6 @@ bool strokeParseOutline(SwStroke& stroke, const SwOutline& outline) for (uint32_t i = 0; i < outline.cntrsCnt; ++i) { auto last = outline.cntrs[i]; //index of last point in contour auto limit = outline.pts + last; - assert(limit); //Skip empty points if (last <= first) { @@ -889,12 +888,8 @@ bool strokeParseOutline(SwStroke& stroke, const SwOutline& outline) } auto start = outline.pts[first]; - auto pt = outline.pts + first; - assert(pt); auto types = outline.types + first; - assert(types); - auto type = types[0]; //A contour cannot start with a cubic control point @@ -903,8 +898,8 @@ bool strokeParseOutline(SwStroke& stroke, const SwOutline& outline) _beginSubPath(stroke, start, outline.opened); while (pt < limit) { - assert(++pt); - assert(++types); + ++pt; + ++types; //emit a signel line_to if (types[0] == SW_CURVE_TYPE_POINT) { -- 2.7.4