diff --git a/common/src/util.cpp b/common/src/util.cpp
index e66bf67e13067e110194f7f011c03bbf3e9e459a..26356d5629322b70ca039f1d31eb872cfef0baa0 100644
--- a/common/src/util.cpp
+++ b/common/src/util.cpp
@@ -12,8 +12,8 @@ float util::long2float(long l)
 long util::float2long(float f)
 {
   float res = f * util::float2longScale;
-  if (f != 0 and res / f != util::float2longScale)
-    util::myThrow(fmt::format("Float '{}' is too big to be converted to long", f));
+  if (f != 0 and std::round(res / f) != std::round(util::float2longScale))
+    util::error(fmt::format("Float '{}' is too big to be converted to long ({}!={})", f, res/f, util::float2longScale));
   
   return res;
 }