Fixed wrong thread handle
Reflects changes made in code