Merge pull request #3388 from ntherning/fix-thread-priority-on-windows