From a15c04cacb81b73e505a2028eac8e8c26b6136d5 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Nicklas=20Av=C3=A9n?= Date: Thu, 20 Aug 2015 20:08:02 +0000 Subject: [PATCH] Fix typo causing wrong answer in 3d-calc in some situations #3251 git-svn-id: http://svn.osgeo.org/postgis/trunk@13960 b70326c6-7e19-0410-871a-916f4a2858ee --- liblwgeom/measures3d.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/liblwgeom/measures3d.c b/liblwgeom/measures3d.c index 77ebeecb5..b3b67e90c 100644 --- a/liblwgeom/measures3d.c +++ b/liblwgeom/measures3d.c @@ -864,12 +864,12 @@ lw_dist3d_seg_seg(POINT3DZ *s1p1, POINT3DZ *s1p2, POINT3DZ *s2p1, POINT3DZ *s2p2 double a, b, c, d, e, D; /*s1p1 and s1p2 are the same point */ - if ( ( s1p1->x == s1p2->x) && (s1p1->y == s1p2->y) && (s1p1->z == s1p2->y) ) + if ( ( s1p1->x == s1p2->x) && (s1p1->y == s1p2->y) && (s1p1->z == s1p2->z) ) { return lw_dist3d_pt_seg(s1p1,s2p1,s2p2,dl); } /*s2p1 and s2p2 are the same point */ - if ( ( s2p1->x == s2p2->x) && (s2p1->y == s2p2->y) && (s2p1->z == s2p2->y) ) + if ( ( s2p1->x == s2p2->x) && (s2p1->y == s2p2->y) && (s2p1->z == s2p2->z) ) { dl->twisted= ((dl->twisted) * (-1)); return lw_dist3d_pt_seg(s2p1,s1p1,s1p2,dl); -- 2.50.1