FileManagerListJob: simplify waiting for worker thread
Wait for the QFuture returned by QtConcurrent::run() to finish instead of custom QSemaphore locking. Thread cancellation and waiting for finished in ~FileManagerListJob() still works as expected. Tested it by inserting `QThread::sleep(5);` right after the `const auto entries =` line in the worker thread lambda and inserting several tracing lines like this: qCritical() << "destroying" << this << QTime::currentTime().second() << QTime::currentTime().msec();
Please register or sign in to comment