Replaced boost::thread_specific_ptr with thread_local

Our static analyzer ignores thread_local but not boost::thread_specific_ptr. It will be changed to also ignore the latter but given thread_local is part of the C++ standard and better reflects what the code was doing, I’ve switched to thread_local.
Merge pull request #1230 from Dr15Jones/switchBoostThreadSpecificPtrToThreadLocal

Multithreading fixes -- Replaced boost::thread_specific_ptr with thread_local.