mirror of
https://github.com/fergalmoran/ladybird.git
synced 2025-12-22 09:19:03 +00:00
AK: Do not negate Pthread error codes for strerror()
On all systems I've checked, pthread functions return the positive error code directly.
This commit is contained in:
committed by
Andreas Kling
parent
6aea13e229
commit
cd0fb6dcc8
@@ -29,11 +29,11 @@ StackInfo::StackInfo()
|
||||
int rc;
|
||||
pthread_attr_t attr = {};
|
||||
if ((rc = pthread_getattr_np(pthread_self(), &attr)) != 0) {
|
||||
fprintf(stderr, "pthread_getattr_np: %s\n", strerror(-rc));
|
||||
fprintf(stderr, "pthread_getattr_np: %s\n", strerror(rc));
|
||||
VERIFY_NOT_REACHED();
|
||||
}
|
||||
if ((rc = pthread_attr_getstack(&attr, (void**)&m_base, &m_size)) != 0) {
|
||||
fprintf(stderr, "pthread_attr_getstack: %s\n", strerror(-rc));
|
||||
fprintf(stderr, "pthread_attr_getstack: %s\n", strerror(rc));
|
||||
VERIFY_NOT_REACHED();
|
||||
}
|
||||
pthread_attr_destroy(&attr);
|
||||
|
||||
Reference in New Issue
Block a user