Fixed ticket #54 (Make cppcheck print status e.g. 4/20 files checked)

This commit is contained in:
Reijo Tomperi 2009-01-24 08:06:40 +00:00
parent 67f30376e1
commit d89f804d91
1 changed files with 9 additions and 1 deletions

View File

@ -242,7 +242,15 @@ unsigned int CppCheck::check()
} }
if (_settings._errorsOnly == false && _errout.str().empty()) if (_settings._errorsOnly == false && _errout.str().empty())
_errorLogger->reportOut("No errors found"); {
std::ostringstream oss;
oss << "No errors found ("
<< (c + 1) << "/" << _filenames.size()
<< " files checked " <<
static_cast<int>(static_cast<double>((c + 1)) / _filenames.size()*100)
<< "% done)";
_errorLogger->reportOut(oss.str());
}
} }
// This generates false positives - especially for libraries // This generates false positives - especially for libraries