the thread_attachX functions already set this

- also fixes OSX memory leak
Merge pull request #437 from dawgfoto/redundantTLS

the thread_attachX functions already set this