From 596968dab92a83ef99001dbd4c0853e57d09f7c9 Mon Sep 17 00:00:00 2001 From: kercylan98 Date: Mon, 5 Jun 2023 19:49:26 +0800 Subject: [PATCH] =?UTF-8?q?=E6=A8=AA=E7=BA=BF=E7=9B=B4=E7=BA=BF=E6=90=9C?= =?UTF-8?q?=E7=B4=A2bug=E5=A4=84=E7=90=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- utils/g2d/shape.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/utils/g2d/shape.go b/utils/g2d/shape.go index 0946c70..0b00ddb 100644 --- a/utils/g2d/shape.go +++ b/utils/g2d/shape.go @@ -259,7 +259,7 @@ func SearchNotRepeatStraightLine(minLength int, xys ...[2]int) (result [][][2]in } if len(find) == 0 { points = nil - } else if len(points) >= minLength { + } else if len(points) >= minLength-1 { goto end } else { points = nil