aboutsummaryrefslogtreecommitdiff
path: root/nss/nsswitch.h
diff options
context:
space:
mode:
authorFlorian Weimer <fweimer@redhat.com>2017-06-30 21:10:23 +0200
committerFlorian Weimer <fweimer@redhat.com>2017-07-03 20:52:59 +0200
commit352f4ff9a268b81ef5d4b2413f582565806e4790 (patch)
treefb27056dfdeafe43c021f6127c9544c016e78019 /nss/nsswitch.h
parent4e45d83c92dbb5b8dc20654f32395108d18cf739 (diff)
downloadglibc-352f4ff9a268b81ef5d4b2413f582565806e4790.zip
glibc-352f4ff9a268b81ef5d4b2413f582565806e4790.tar.gz
glibc-352f4ff9a268b81ef5d4b2413f582565806e4790.tar.bz2
resolv: Introduce struct resolv_context [BZ #21668]
struct resolv_context objects provide a temporary resolver context which does not change during a name lookup operation. Only when the outmost context is created, the stub resolver configuration is verified to be current (at present, only against previous res_init calls). Subsequent attempts to obtain the context will reuse the result of the initial verification operation. struct resolv_context can also be extended in the future to store data which needs to be deallocated during thread cancellation.
Diffstat (limited to 'nss/nsswitch.h')
-rw-r--r--nss/nsswitch.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/nss/nsswitch.h b/nss/nsswitch.h
index f3e756b..bd3fbcb 100644
--- a/nss/nsswitch.h
+++ b/nss/nsswitch.h
@@ -197,7 +197,17 @@ extern int __nss_getent_r (const char *getent_func_name,
extern void *__nss_getent (getent_r_function func,
void **resbuf, char **buffer, size_t buflen,
size_t *buffer_size, int *h_errnop);
+struct resolv_context;
struct hostent;
+extern int __nss_hostname_digits_dots_context (struct resolv_context *,
+ const char *name,
+ struct hostent *resbuf,
+ char **buffer,
+ size_t *buffer_size,
+ size_t buflen,
+ struct hostent **result,
+ enum nss_status *status, int af,
+ int *h_errnop) attribute_hidden;
extern int __nss_hostname_digits_dots (const char *name,
struct hostent *resbuf, char **buffer,
size_t *buffer_size, size_t buflen,