diff --git a/src/core/deletefiles.cpp b/src/core/deletefiles.cpp index 6b5bd5b65..98a623cde 100644 --- a/src/core/deletefiles.cpp +++ b/src/core/deletefiles.cpp @@ -108,7 +108,7 @@ void DeleteFiles::ProcessSomeFiles() { // We process files in batches so we can be cancelled part-way through. - const qint64 n = qMin(songs_.count(), static_cast(progress_ + kBatchSize)); + const qint64 n = qMin(static_cast(songs_.count()), static_cast(progress_ + kBatchSize)); for (; progress_ < n; ++progress_) { task_manager_->SetTaskProgress(task_id_, progress_, songs_.count());