From 5c984be41f0a03aee57901fd25abbdbb943ad116 Mon Sep 17 00:00:00 2001 From: wmayer Date: Tue, 11 Sep 2018 11:33:38 +0200 Subject: [PATCH] replace epsilon to check for null vector --- src/Base/VectorPyImp.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Base/VectorPyImp.cpp b/src/Base/VectorPyImp.cpp index 2b698d7a2a..ba7406d63d 100644 --- a/src/Base/VectorPyImp.cpp +++ b/src/Base/VectorPyImp.cpp @@ -612,7 +612,7 @@ void VectorPy::setLength(Py::Float arg) { VectorPy::PointerType ptr = reinterpret_cast(_pcTwinPointer); double len = ptr->Length(); - if (len < 1.0e-6) { + if (len < Vector3d::epsilon()) { throw Py::RuntimeError(std::string("Cannot set length of null vector")); }