[postgis-tickets] [SCM] PostGIS branch stable-2.5 updated. 2.5.5-10-gcfae0f1

git at osgeo.org git at osgeo.org
Mon Jul 26 14:34:22 PDT 2021


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "PostGIS".

The branch, stable-2.5 has been updated
       via  cfae0f165d39f204bbfd412c83c5017f15541887 (commit)
      from  586f6367ee850c7963f2c492769d68b7e8596ae0 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit cfae0f165d39f204bbfd412c83c5017f15541887
Author: Paul Ramsey <pramsey at cleverelephant.ca>
Date:   Mon Jul 26 14:34:17 2021 -0700

    Error in arc direction flagging, fixes #4326

diff --git a/NEWS b/NEWS
index b5a0fc3..9357e3f 100644
--- a/NEWS
+++ b/NEWS
@@ -8,6 +8,7 @@ YYYY/MM/DD
   - #4757, Handle line collapse due to snap-to-existing node (Sandro Santilli)
   - #4769, Fix segfault in st_addband (Raúl Marín)
   - #4863, Update bboxes after affine/scale operations (Paul Ramsey)
+  - #4326, Fix CircularPolygon area calculation (Paul Ramsey)
 
 
 PostGIS 2.5.5
diff --git a/liblwgeom/cunit/cu_measures.c b/liblwgeom/cunit/cu_measures.c
index 241052c..0e1cc07 100644
--- a/liblwgeom/cunit/cu_measures.c
+++ b/liblwgeom/cunit/cu_measures.c
@@ -201,6 +201,12 @@ static void test_mindistance2d_tolerance(void)
 	*/
 	DIST2DTEST("LINESTRING(0.5 1,0.5 3)", "MULTICURVE(CIRCULARSTRING(2 3,3 2,2 1,1 2,2 3),(0 0, 0 5))", 0.5);
 
+	/*
+	** Ticket 4326
+	*/
+	DIST2DTEST(
+		"CURVEPOLYGON(CIRCULARSTRING(7874821 8715927,8907663 8715927,8844683 7750316,7937800 7750316,7874821 8715927))",
+		"POINT(5433865 8243495)", 2271704.2698450615, default_accepted_error);
 }
 
 static void
diff --git a/liblwgeom/ptarray.c b/liblwgeom/ptarray.c
index 3ad5f5f..2e576e1 100644
--- a/liblwgeom/ptarray.c
+++ b/liblwgeom/ptarray.c
@@ -943,7 +943,7 @@ ptarrayarc_contains_point_partial(const POINTARRAY *pa, const POINT2D *pt, int c
 		}
 
 		/* Going "down"! */
-		if ( side > 0 && (seg2->y <= pt->y) && (pt->y < seg1->y) )
+		if ( side > 0 && (seg3->y <= pt->y) && (pt->y < seg1->y) )
 		{
 			wn--;
 		}

-----------------------------------------------------------------------

Summary of changes:
 NEWS                          | 1 +
 liblwgeom/cunit/cu_measures.c | 6 ++++++
 liblwgeom/ptarray.c           | 2 +-
 3 files changed, 8 insertions(+), 1 deletion(-)


hooks/post-receive
-- 
PostGIS


More information about the postgis-tickets mailing list