diff options
-rw-r--r-- | include/resolv.h | 1 | ||||
-rw-r--r-- | libc/inet/resolv.c | 1 |
2 files changed, 2 insertions, 0 deletions
diff --git a/include/resolv.h b/include/resolv.h index 3b18be6b9..e0cd35db1 100644 --- a/include/resolv.h +++ b/include/resolv.h @@ -436,6 +436,7 @@ extern __thread struct __res_state *__resp attribute_tls_model_ie; # else # undef _res # define _res (*__resp) +extern struct __res_state *__resp; # endif /* __UCLIBC_HAS_TLS__ */ # endif /* __UCLIBC_HAS_THREADS__ */ # endif /* _LIBC */ diff --git a/libc/inet/resolv.c b/libc/inet/resolv.c index 7d501f640..ca191ac4e 100644 --- a/libc/inet/resolv.c +++ b/libc/inet/resolv.c @@ -2995,6 +2995,7 @@ void res_close(void) create a common definition, but a plain symbol that resides in .bss, which can have an alias. */ struct __res_state _res __attribute__((section (".bss"))); +struct __res_state *__resp = &_res; #else //__UCLIBC_HAS_THREADS__ struct __res_state _res __attribute__((section (".bss"))) attribute_hidden; |