mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 11:28:12 +00:00
AK: Fix preprocessor OS check
Instead of checking __linux__ macro directly, the code should check if this macro is defined. This is already done correctly a couple of lines above. I ran into this when trying to build libjs-test262 on MacOS where I got the following error message error: "__linux__" is not defined, evaluates to 0 [-Werror=undef]
This commit is contained in:
parent
5f1a34bba3
commit
c4c8f59284
1 changed files with 1 additions and 1 deletions
|
@ -25,7 +25,7 @@ StackInfo::StackInfo()
|
||||||
perror("get_stack_bounds");
|
perror("get_stack_bounds");
|
||||||
VERIFY_NOT_REACHED();
|
VERIFY_NOT_REACHED();
|
||||||
}
|
}
|
||||||
#elif __linux__
|
#elif defined(__linux__)
|
||||||
int rc;
|
int rc;
|
||||||
pthread_attr_t attr = {};
|
pthread_attr_t attr = {};
|
||||||
if ((rc = pthread_getattr_np(pthread_self(), &attr)) != 0) {
|
if ((rc = pthread_getattr_np(pthread_self(), &attr)) != 0) {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue