Return value of Thread::setPriority

At least the windows implementation of juce_setThreadPriority can fail (if SetPriority fails). See http://msdn.microsoft.com/en-us/library/ms686277(VS.85).aspx.

Would you consider checking the return value of SetPriority in juce_setThreadPriority and changing the return type to bool to indicate success/failure, and then continuing up the chain to return that info from Thread::setPriority and ThreadPool::setThreadPriorities.

Thanks.

-DB

Ok, sounds like a good request. What’s your fallback plan if it fails, though?

It’s really just so apps know what’s going on. Log a message with the value of GetLastError (on Windows) and return failure and then if an app wants to try again, it knows to do that. I’m not sure there’s much else an app can do besides retry.

-DB