projects
/
musl
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
elf.h: add ELFCOMPRESS_ZSTD
[musl]
/
src
/
network
/
h_errno.c
diff --git
a/src/network/h_errno.c
b/src/network/h_errno.c
index
5560234
..
638f771
100644
(file)
--- a/
src/network/h_errno.c
+++ b/
src/network/h_errno.c
@@
-1,9
+1,11
@@
#include <netdb.h>
+#include "pthread_impl.h"
-#undef h_errno
;
+#undef h_errno
int h_errno;
int *__h_errno_location(void)
{
- return &h_errno;
+ if (!__pthread_self()->stack) return &h_errno;
+ return &__pthread_self()->h_errno_val;
}