You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by rm...@apache.org on 2022/11/24 21:33:34 UTC
[lucene] branch branch_9x updated: Fix GeoDegeneratePath compile error (#11975)
This is an automated email from the ASF dual-hosted git repository.
rmuir pushed a commit to branch branch_9x
in repository https://gitbox.apache.org/repos/asf/lucene.git
The following commit(s) were added to refs/heads/branch_9x by this push:
new 55f9b513c4b Fix GeoDegeneratePath compile error (#11975)
55f9b513c4b is described below
commit 55f9b513c4b437006fbc7126a8d58a319ee09a46
Author: Luca Cavanna <ja...@users.noreply.github.com>
AuthorDate: Thu Nov 24 22:33:28 2022 +0100
Fix GeoDegeneratePath compile error (#11975)
---
.../java/org/apache/lucene/spatial3d/geom/GeoDegeneratePath.java | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/lucene/spatial3d/src/java/org/apache/lucene/spatial3d/geom/GeoDegeneratePath.java b/lucene/spatial3d/src/java/org/apache/lucene/spatial3d/geom/GeoDegeneratePath.java
index 73ab6522475..bba5a016c16 100644
--- a/lucene/spatial3d/src/java/org/apache/lucene/spatial3d/geom/GeoDegeneratePath.java
+++ b/lucene/spatial3d/src/java/org/apache/lucene/spatial3d/geom/GeoDegeneratePath.java
@@ -497,8 +497,10 @@ class GeoDegeneratePath extends GeoBasePath {
*/
public double pathCenterDistance(
final DistanceStyle distanceStyle, final double x, final double y, final double z) {
- if (!isWithinSection(x, y, z)) {
- return Double.POSITIVE_INFINITY;
+ for (final Membership m : cutoffPlanes) {
+ if (!m.isWithin(x, y, z)) {
+ return Double.POSITIVE_INFINITY;
+ }
}
return distanceStyle.toAggregationForm(distanceStyle.computeDistance(this.point, x, y, z));
}