cppcheckexecutor: removed time info from verbose progress info. the ctime function that is used is not threadsafe.

This commit is contained in:
Daniel Marjamäki 2012-12-09 09:30:18 +01:00
parent a11ec4a5ee
commit b107e5e9e8
1 changed files with 0 additions and 5 deletions

View File

@ -249,16 +249,11 @@ void CppCheckExecutor::reportProgress(const std::string &filename, const char st
if (time2 >= (time1 + 10)) { if (time2 >= (time1 + 10)) {
time1 = time2; time1 = time2;
// current time in the format "Www Mmm dd hh:mm:ss yyyy"
const std::string str(std::ctime(&time2));
// format a progress message // format a progress message
std::ostringstream ostr; std::ostringstream ostr;
ostr << "progress: " ostr << "progress: "
<< stage << stage
<< ' ' << value << '%'; << ' ' << value << '%';
if (_settings->_verbose)
ostr << " time=" << str.substr(11, 8);
// Report progress message // Report progress message
reportOut(ostr.str()); reportOut(ostr.str());