diff options
author | 2015-10-07 13:59:34 +0000 | |
---|---|---|
committer | 2015-10-07 13:59:34 +0000 | |
commit | 656b8d513650c05e27d8c5044c6432310062d847 (patch) | |
tree | 5606c4df6b6c984719f47e0443ec9837bdf4f12a /lib/libc/asr/asr.c | |
parent | getaddrinfo() should not res_init() unconditionally, but allow lower (diff) | |
download | wireguard-openbsd-656b8d513650c05e27d8c5044c6432310062d847.tar.xz wireguard-openbsd-656b8d513650c05e27d8c5044c6432310062d847.zip |
getaddrinfo_async() shouldn't unconditionally intialize the resolver
via _asr_use_resolver(). If the hint specifies for AI_NUMERICHOST,
create a transient lookup context which won't try to open /etc/reslov.conf
ok eric guenther
Diffstat (limited to 'lib/libc/asr/asr.c')
-rw-r--r-- | lib/libc/asr/asr.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/lib/libc/asr/asr.c b/lib/libc/asr/asr.c index 1f6429f5109..7c13122a8cb 100644 --- a/lib/libc/asr/asr.c +++ b/lib/libc/asr/asr.c @@ -1,4 +1,4 @@ -/* $OpenBSD: asr.c,v 1.45 2015/10/03 22:35:30 deraadt Exp $ */ +/* $OpenBSD: asr.c,v 1.46 2015/10/07 13:59:34 deraadt Exp $ */ /* * Copyright (c) 2010-2012 Eric Faurot <eric@openbsd.org> * @@ -489,6 +489,12 @@ asr_ctx_create(void) return (ac); } +struct asr_ctx * +_asr_no_resolver(void) +{ + return asr_ctx_create(); +} + /* * Add a search domain to the async context. */ |