0020569: EDF 1158 SMESH: Bad interpretation of analytical density function in 1D distribution hypothesis

This commit is contained in:
dmv 2009-11-03 07:48:31 +00:00
parent 42c6f09fd9
commit 10c15ac1c2

View File

@ -321,6 +321,10 @@ bool process( const TCollection_AsciiString& str, int convMode,
bool& non_neg, bool& non_zero,
bool& singulars, double& sing_point )
{
// Set "C" numeric locale to save numbers correctly
std::string aCurLocale = setlocale(LC_NUMERIC, 0);
setlocale(LC_NUMERIC, "C");
bool parsed_ok = true;
Handle( ExprIntrp_GenExp ) myExpr;
try {
@ -372,6 +376,10 @@ bool process( const TCollection_AsciiString& str, int convMode,
non_zero = true;
}
}
// Return previous locale
setlocale(LC_NUMERIC, aCurLocale.data());
return res && non_neg && non_zero && ( !singulars );
}