diff options
Diffstat (limited to 'libc/misc/internals/__h_errno_location.c')
-rw-r--r-- | libc/misc/internals/__h_errno_location.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/libc/misc/internals/__h_errno_location.c b/libc/misc/internals/__h_errno_location.c index 113677682..41353d74a 100644 --- a/libc/misc/internals/__h_errno_location.c +++ b/libc/misc/internals/__h_errno_location.c @@ -4,10 +4,16 @@ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. */ -#include "internal_errno.h" +#include <features.h> +#include <netdb.h> + +#ifndef __UCLIBC_HAS_TLS__ +# undef h_errno +extern int h_errno; +#endif int *__h_errno_location(void) { return &h_errno; } -libc_hidden_weak(__h_errno_location) +libc_hidden_def(__h_errno_location) |