From aad71902c94b3bc21ab34b0e2c92972400921574 Mon Sep 17 00:00:00 2001 From: Thomas White Date: Wed, 11 Sep 2019 17:05:33 +0200 Subject: Fix sign of zl comparison --- libcrystfel/src/geometry.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'libcrystfel/src/geometry.c') diff --git a/libcrystfel/src/geometry.c b/libcrystfel/src/geometry.c index 5b2107d1..fc42a8de 100644 --- a/libcrystfel/src/geometry.c +++ b/libcrystfel/src/geometry.c @@ -332,7 +332,7 @@ static Reflection *check_reflection(struct image *image, Crystal *cryst, /* Closest point on Ewald sphere. * Project zl to 0, bit of a hack... */ - const double zlp0 = zl>0?zl:0; + const double zlp0 = zl<0?zl:0; exerr2 = (x-xl)*(x-xl) + (y-yl)*(y-yl) + (z-zl)*(z-zl); /* Weighted average between projected lattice point -- cgit v1.2.3