mirror of
https://github.com/anrieff/libcpuid
synced 2024-12-16 16:35:45 +00:00
Merge pull request #142 from ClickHouse-Extras/fix-tsan
Fix TSan report
This commit is contained in:
commit
8db3b8d2d3
1 changed files with 7 additions and 1 deletions
|
@ -38,7 +38,13 @@
|
|||
|
||||
/* Implementation: */
|
||||
|
||||
#if defined(__STDC_VERSION__) && __STDC_VERSION__ == 201112L
|
||||
_Thread_local int _libcpiud_errno = ERR_OK;
|
||||
#elif defined(__GNUC__) // Also works for clang
|
||||
__thread int _libcpiud_errno = ERR_OK;
|
||||
#else
|
||||
static int _libcpiud_errno = ERR_OK;
|
||||
#endif
|
||||
|
||||
int set_error(cpu_error_t err)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue