You can use
Qt Code:
  1. QThreadPool::globalInstance->setMaxThreadCount()
To copy to clipboard, switch view to plain text mode 
to limit the number of threads.
And if your application still is crashing, you are probably still accessing a shared variable in an unsafe way. I'm thinking of myList and allFiles.
It sounds like QtConcurrent::mappedReduced could be a candidate for you.