1
0
Fork 0
mirror of https://github.com/anrieff/libcpuid synced 2025-02-12 20:24:05 +00:00

Fix typo in variable name

This commit is contained in:
Xorg 2022-09-25 10:11:39 +02:00
parent 871840f8e5
commit 10b4e46179
No known key found for this signature in database
GPG key ID: 1E55EE2EFF18BC1A

View file

@ -40,16 +40,16 @@
/* Implementation: */ /* Implementation: */
#if defined(__STDC_VERSION__) && __STDC_VERSION__ == 201112L #if defined(__STDC_VERSION__) && __STDC_VERSION__ == 201112L
_Thread_local int _libcpiud_errno = ERR_OK; _Thread_local int _libcpuid_errno = ERR_OK;
#elif defined(__GNUC__) // Also works for clang #elif defined(__GNUC__) // Also works for clang
__thread int _libcpiud_errno = ERR_OK; __thread int _libcpuid_errno = ERR_OK;
#else #else
static int _libcpiud_errno = ERR_OK; static int _libcpuid_errno = ERR_OK;
#endif #endif
int set_error(cpu_error_t err) int set_error(cpu_error_t err)
{ {
_libcpiud_errno = (int) err; _libcpuid_errno = (int) err;
return (int) err; return (int) err;
} }
@ -1382,7 +1382,7 @@ const char* cpuid_error(void)
}; };
unsigned i; unsigned i;
for (i = 0; i < COUNT_OF(matchtable); i++) for (i = 0; i < COUNT_OF(matchtable); i++)
if (_libcpiud_errno == matchtable[i].error) if (_libcpuid_errno == matchtable[i].error)
return matchtable[i].description; return matchtable[i].description;
return "Unknown error"; return "Unknown error";
} }