Don't clobber GetLastError in Win32 systhreads
See also PR 10220 and issue 8857.
SetLastError is called when accessing the TLS value This_thread.
(cherry picked from commit 93843575809433ea50e0406d56c0681287411f1b)
authored by