[postgis-tickets] [SCM] PostGIS branch master updated. 3.1.0alpha3-35-g561428e

git at osgeo.org git at osgeo.org
Mon Dec 7 12:47:02 PST 2020


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, master has been updated
       via  561428ea62b10796c8846d48011f972eaeb37c43 (commit)
      from  4619ebd23680a985bfa0ee758b6f5999fb6fe863 (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 561428ea62b10796c8846d48011f972eaeb37c43
Author: Paul Ramsey <pramsey at cleverelephant.ca>
Date:   Mon Dec 7 12:46:56 2020 -0800

    Handle SRID=999999 consistently with other high SRID numbers. Closes #4812

diff --git a/liblwgeom/lwin_wkt.c b/liblwgeom/lwin_wkt.c
index ab91383..d911663 100644
--- a/liblwgeom/lwin_wkt.c
+++ b/liblwgeom/lwin_wkt.c
@@ -869,7 +869,7 @@ wkt_parser_geometry_new(LWGEOM *geom, int32_t srid)
 		return;
 	}
 
-	if ( srid != SRID_UNKNOWN && srid < SRID_MAXIMUM )
+	if ( srid != SRID_UNKNOWN && srid <= SRID_MAXIMUM )
 		lwgeom_set_srid(geom, srid);
 	else
 		lwgeom_set_srid(geom, SRID_UNKNOWN);
diff --git a/regress/core/tickets.sql b/regress/core/tickets.sql
index 956a49c..6acda49 100644
--- a/regress/core/tickets.sql
+++ b/regress/core/tickets.sql
@@ -1314,3 +1314,5 @@ SELECT '#4727', _ST_DistanceTree('SRID=4326;POLYGON((-179.9 -85.05112877980659,
 				ST_MakePoint(-150,-40), 0.0, true);
 
 SELECT '#4796', st_astext(st_snaptogrid(st_normalize(st_simplifypreservetopology('MULTISURFACE(((178632.044 397744.007,178631.118 397743.786,178646.399 397679.574,178693.864 397690.889,178698.958 397669.487,178700.206 397669.784,178758.532 397683.689,178748.351 397726.468,178752.199 397727.384,178748.782 397741.904,178744.897 397740.98,178738.157 397769.303,178632.044 397744.007)))'::geometry,1)),1));
+
+SELECT '#4812', st_srid('SRID=999999;POINT(1 1)'::geometry);
diff --git a/regress/core/tickets_expected b/regress/core/tickets_expected
index 1d56d2e..bc1f71a 100644
--- a/regress/core/tickets_expected
+++ b/regress/core/tickets_expected
@@ -438,3 +438,4 @@ ERROR:  LWGEOM_addpoint: Invalid offset
 #4718|270.000|90.000
 #4727|0
 #4796|POLYGON((178632 397744,178738 397769,178745 397741,178749 397742,178752 397727,178748 397726,178759 397684,178699 397669,178694 397691,178646 397680,178632 397744))
+#4812|999999

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

Summary of changes:
 liblwgeom/lwin_wkt.c          | 2 +-
 regress/core/tickets.sql      | 2 ++
 regress/core/tickets_expected | 1 +
 3 files changed, 4 insertions(+), 1 deletion(-)


hooks/post-receive
-- 
PostGIS


More information about the postgis-tickets mailing list