From d18e518db6c21b9096bd91f69d595dc7fa46f991 Mon Sep 17 00:00:00 2001 From: Florian BRUNET Date: Wed, 8 Apr 2015 11:48:32 +0200 Subject: [PATCH] Force the float expression for the max memory parameter to avoid exponential form incompatible so far with MG-tetra as soon as the requested memory value is greater than 1TB. --- src/GHS3DPlugin/GHS3DPlugin_Hypothesis.cxx | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/GHS3DPlugin/GHS3DPlugin_Hypothesis.cxx b/src/GHS3DPlugin/GHS3DPlugin_Hypothesis.cxx index e1eb1ed..f8a7c69 100644 --- a/src/GHS3DPlugin/GHS3DPlugin_Hypothesis.cxx +++ b/src/GHS3DPlugin/GHS3DPlugin_Hypothesis.cxx @@ -1481,11 +1481,13 @@ std::string GHS3DPlugin_Hypothesis::CommandToRun(const GHS3DPlugin_Hypothesis* h // so allow to use about all available memory if ( m ) { double aMaximumMemory = hyp ? hyp->myMaximumMemory : -1; + ostringstream tmpMaximumMemory; cmd += " -m "; if ( aMaximumMemory < 0 ) - cmd += DefaultMaximumMemory(); + tmpMaximumMemory << std::fixed << std::setprecision(0) << DefaultMaximumMemory(); else - cmd += aMaximumMemory; + tmpMaximumMemory << std::fixed << std::setprecision(0) << aMaximumMemory; + cmd += tmpMaximumMemory.str().c_str(); } if ( M && !useBndRecovery ) { double aInitialMemory = hyp ? hyp->myInitialMemory : -1; -- 2.39.2