[opengm] 23/40: fix amazing bug in test-marco

Ghislain Vaillant ghisvail-guest at moszumanska.debian.org
Sun Feb 14 16:06:02 UTC 2016


This is an automated email from the git hooks/post-receive script.

ghisvail-guest pushed a commit to branch master
in repository opengm.

commit 83611ee71eab3f6a4c22c75db117441d145434b6
Author: joergkappes <kappes at math.uni-heidelberg.de>
Date:   Thu Dec 3 16:43:28 2015 +0100

    fix amazing bug in test-marco
---
 include/opengm/unittests/test.hxx | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/include/opengm/unittests/test.hxx b/include/opengm/unittests/test.hxx
index 69343cb..54e8691 100644
--- a/include/opengm/unittests/test.hxx
+++ b/include/opengm/unittests/test.hxx
@@ -29,7 +29,7 @@
 }
 
 #define OPENGM_TEST_EQUAL_TOLERANCE(x, y, epsilon) \
-    if( (x<y && y-x > epsilon) || (x>y && x-y > epsilon) ) { \
+   if( (x<y && y-epsilon > x) || (x>y && x-epsilon > y) ) {        \
     std::stringstream s; \
     s << x << " != " << y << " [line " << __LINE__ << ": " << #x << " == " << #y << " ]"; \
     throw std::logic_error(s.str().c_str()); \

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/opengm.git



More information about the debian-science-commits mailing list