diff --git a/OpenSim/Common/IO.cpp b/OpenSim/Common/IO.cpp index dfe2d4e078..bd442129fc 100644 --- a/OpenSim/Common/IO.cpp +++ b/OpenSim/Common/IO.cpp @@ -480,6 +480,11 @@ OpenOutputFile(const string &aFileName,ios_base::openmode mode) double IO:: stod(const std::string& __str, std::size_t* __idx) { + double result; + struct ios_base : public std::ios_base {} s3; + s3.imbue(_locale); + std::ios::iostate err = std::ios_base::goodbit; + std::use_facet< std::num_get< char, std::string::const_iterator > >( s3.getloc() ).get( __str.begin(), __str.end(), s3, err, result ); // std::istringstream iss(__str); // iss.imbue(_locale); // double result = 0.0;