[geos-commits] [SCM] GEOS branch 3.11 updated. 72b0c32d012bbb078e6ba83b49b2676c340949a0

git at osgeo.org git at osgeo.org
Sat Jun 20 05:09:10 PDT 2026


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 "GEOS".

The branch, 3.11 has been updated
       via  72b0c32d012bbb078e6ba83b49b2676c340949a0 (commit)
       via  3ea733fad5ee52d828d5e83feae667eb7788576c (commit)
      from  0576a1fd2a49ef2c7b1abc7245e769565b169b02 (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 72b0c32d012bbb078e6ba83b49b2676c340949a0
Author: Daniel Baston <dbaston at gmail.com>
Date:   Thu Jun 18 12:49:34 2026 -0400

    KdTree: Disable optimizations in latest MSVC version
    
    References #1449

diff --git a/src/index/kdtree/KdTree.cpp b/src/index/kdtree/KdTree.cpp
index a0c2dfbff..9142a0789 100644
--- a/src/index/kdtree/KdTree.cpp
+++ b/src/index/kdtree/KdTree.cpp
@@ -226,6 +226,11 @@ KdTree::queryNode(KdNode* currentNode, const geom::Envelope& queryEnv, bool odd,
     }
 }
 
+#if defined(_MSC_VER) && _MSC_FULL_VER > 195035734
+// Avoid segfault with MSVC 19.51.36246.0
+// See https://github.com/libgeos/geos/issues/1449
+#pragma optimize("", off)
+#endif
 /*private*/
 KdNode*
 KdTree::queryNodePoint(KdNode* currentNode, const geom::Coordinate& queryPt, bool odd)
@@ -257,7 +262,9 @@ KdTree::queryNodePoint(KdNode* currentNode, const geom::Coordinate& queryPt, boo
     }
     return nullptr;
 }
-
+#if defined(_MSC_VER) && _MSC_FULL_VER > 195035734
+#pragma optimize("", on)
+#endif
 
 /*public*/
 void

commit 3ea733fad5ee52d828d5e83feae667eb7788576c
Author: Daniel Baston <dbaston at gmail.com>
Date:   Fri Jun 19 09:24:45 2026 -0400

    KdTree: Add minimal test for #1449

diff --git a/tests/unit/index/kdtree/KdTreeTest.cpp b/tests/unit/index/kdtree/KdTreeTest.cpp
index 2de94f162..1121ca25b 100644
--- a/tests/unit/index/kdtree/KdTreeTest.cpp
+++ b/tests/unit/index/kdtree/KdTreeTest.cpp
@@ -189,6 +189,24 @@ void object::test<8> ()
     ensure(node->isRepeated());
 }
 
+template<>
+template<>
+void object::test<9>()
+{
+    set_test_name("query by point");
+    // minimal test for https://github.com/libgeos/geos/issues/1449
+
+    KdTree index;
+    ensure(index.query({ 6, 8 }) == nullptr);
+
+    const KdNode* node68 = index.insert({ 6, 8 });
+    ensure(node68);
+    ensure_equals(index.query({ 6, 8 }), node68);
+
+    const KdNode* node28 = index.insert({ 2, 8 });
+    ensure(node28);
+    ensure_equals(index.query({ 2, 8 }), node28);
+}
 
 
 

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

Summary of changes:
 src/index/kdtree/KdTree.cpp            |  9 ++++++++-
 tests/unit/index/kdtree/KdTreeTest.cpp | 18 ++++++++++++++++++
 2 files changed, 26 insertions(+), 1 deletion(-)


hooks/post-receive
-- 
GEOS


More information about the geos-commits mailing list