Better variable names
This commit is contained in:
parent
cad30446e4
commit
93e5140945
|
@ -78,7 +78,7 @@
|
||||||
/*static*/ FILE* CppCheckExecutor::exceptionOutput = stdout;
|
/*static*/ FILE* CppCheckExecutor::exceptionOutput = stdout;
|
||||||
|
|
||||||
CppCheckExecutor::CppCheckExecutor()
|
CppCheckExecutor::CppCheckExecutor()
|
||||||
: _settings(nullptr), time1(0), errorOutput(nullptr), errorlist(false)
|
: _settings(nullptr), latestProgressOutputTime(0), errorOutput(nullptr), errorlist(false)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -828,7 +828,7 @@ int CppCheckExecutor::check_internal(CppCheck& cppcheck, int /*argc*/, const cha
|
||||||
}
|
}
|
||||||
|
|
||||||
if (settings.reportProgress)
|
if (settings.reportProgress)
|
||||||
time1 = std::time(nullptr);
|
latestProgressOutputTime = std::time(nullptr);
|
||||||
|
|
||||||
if (!settings.outputFile.empty()) {
|
if (!settings.outputFile.empty()) {
|
||||||
errorOutput = new std::ofstream(settings.outputFile);
|
errorOutput = new std::ofstream(settings.outputFile);
|
||||||
|
@ -989,13 +989,13 @@ void CppCheckExecutor::reportProgress(const std::string &filename, const char st
|
||||||
{
|
{
|
||||||
(void)filename;
|
(void)filename;
|
||||||
|
|
||||||
if (!time1)
|
if (!latestProgressOutputTime)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
// Report progress messages every 10 seconds
|
// Report progress messages every 10 seconds
|
||||||
const std::time_t time2 = std::time(nullptr);
|
const std::time_t currentTime = std::time(nullptr);
|
||||||
if (time2 >= (time1 + 10)) {
|
if (currentTime >= (latestProgressOutputTime + 10)) {
|
||||||
time1 = time2;
|
latestProgressOutputTime = currentTime;
|
||||||
|
|
||||||
// format a progress message
|
// format a progress message
|
||||||
std::ostringstream ostr;
|
std::ostringstream ostr;
|
||||||
|
|
|
@ -175,7 +175,7 @@ private:
|
||||||
/**
|
/**
|
||||||
* Report progress time
|
* Report progress time
|
||||||
*/
|
*/
|
||||||
std::time_t time1;
|
std::time_t latestProgressOutputTime;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Output file name for exception handler
|
* Output file name for exception handler
|
||||||
|
|
Loading…
Reference in New Issue