diff options
| author | 2019-12-13 16:18:54 +0000 | |
|---|---|---|
| committer | 2019-12-13 16:18:54 +0000 | |
| commit | a89affb08787faea32b2561190616417adf1037f (patch) | |
| tree | cafd97405e1fbe5f49f9d9c0274a60d8f3138faf | |
| parent | print type as type and not as rcode (diff) | |
| download | wireguard-openbsd-a89affb08787faea32b2561190616417adf1037f.tar.xz wireguard-openbsd-a89affb08787faea32b2561190616417adf1037f.zip | |
Don't try dead resolvers; ok florian@
| -rw-r--r-- | sbin/unwind/resolver.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/sbin/unwind/resolver.c b/sbin/unwind/resolver.c index 2ad8621a9f8..59bab341970 100644 --- a/sbin/unwind/resolver.c +++ b/sbin/unwind/resolver.c @@ -1,4 +1,4 @@ -/* $OpenBSD: resolver.c,v 1.109 2019/12/13 15:10:04 otto Exp $ */ +/* $OpenBSD: resolver.c,v 1.110 2019/12/13 16:18:54 otto Exp $ */ /* * Copyright (c) 2018 Florian Obser <florian@openbsd.org> @@ -758,7 +758,8 @@ try_next_resolver(struct running_query *rq) char qtype_buf[16]; while(rq->next_resolver < rq->res_pref.len && - (res=resolvers[rq->res_pref.types[rq->next_resolver]]) == NULL) + ((res = resolvers[rq->res_pref.types[rq->next_resolver]]) == NULL || + res->state == DEAD)) rq->next_resolver++; if (res == NULL) { |
