Small thread code cleanup
Small thread code cleanup