shared: Indexer: Fix case where errors did not increase counter
This commit is contained in:
parent
9540f27c95
commit
6cd7a92576
@ -111,6 +111,20 @@ void Indexer::dirScanProgress(int current, int total)
|
||||
|
||||
void Indexer::processFileScanResult(FileScanResult result)
|
||||
{
|
||||
/* TODO: OK_WASEMPTY might need a special list */
|
||||
if(result.second == OK || result.second == OK_WASEMPTY)
|
||||
{
|
||||
++this->currentIndexResult.addedPaths;
|
||||
}
|
||||
else if(result.second == SKIPPED)
|
||||
{
|
||||
++this->currentIndexResult.skippedPaths;
|
||||
}
|
||||
else
|
||||
{
|
||||
++this->currentIndexResult.erroredPaths;
|
||||
}
|
||||
|
||||
if(isErrorSaveFileResult(result.second))
|
||||
{
|
||||
this->currentIndexResult.results.append(result);
|
||||
@ -129,20 +143,6 @@ void Indexer::processFileScanResult(FileScanResult result)
|
||||
}
|
||||
}
|
||||
|
||||
/* TODO: OK_WASEMPTY might need a special list */
|
||||
if(result.second == OK || result.second == OK_WASEMPTY)
|
||||
{
|
||||
++this->currentIndexResult.addedPaths;
|
||||
}
|
||||
else if(result.second == SKIPPED)
|
||||
{
|
||||
++this->currentIndexResult.skippedPaths;
|
||||
}
|
||||
else
|
||||
{
|
||||
++this->currentIndexResult.erroredPaths;
|
||||
}
|
||||
|
||||
QTime currentTime = QTime::currentTime();
|
||||
if(currentScanProcessedCount++ == progressReportThreshold || this->lastProgressReportTime.secsTo(currentTime) >= 10)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user