diff options
author | 2013-03-29 20:04:17 +0000 | |
---|---|---|
committer | 2013-03-29 20:04:17 +0000 | |
commit | 1a003af8fd623992d1d106a32e49cad91fc6e2d7 (patch) | |
tree | ff58d1600fa76f42abe1d57a3954aec4f74f2422 /lib/libc/asr/gethostnamadr_async.c | |
parent | Properly release ccbs when restarting a work unit. (diff) | |
download | wireguard-openbsd-1a003af8fd623992d1d106a32e49cad91fc6e2d7.tar.xz wireguard-openbsd-1a003af8fd623992d1d106a32e49cad91fc6e2d7.zip |
Do not fail in gethostbyname_async() if there are multiple addresses in
a DNS packet...
Diffstat (limited to 'lib/libc/asr/gethostnamadr_async.c')
-rw-r--r-- | lib/libc/asr/gethostnamadr_async.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/libc/asr/gethostnamadr_async.c b/lib/libc/asr/gethostnamadr_async.c index 33ec8b571cc..be9bb1f392e 100644 --- a/lib/libc/asr/gethostnamadr_async.c +++ b/lib/libc/asr/gethostnamadr_async.c @@ -1,4 +1,4 @@ -/* $OpenBSD: gethostnamadr_async.c,v 1.13 2013/03/27 07:40:41 eric Exp $ */ +/* $OpenBSD: gethostnamadr_async.c,v 1.14 2013/03/29 20:04:17 eric Exp $ */ /* * Copyright (c) 2012 Eric Faurot <eric@openbsd.org> * @@ -500,7 +500,7 @@ hostent_from_packet(int reqtype, int family, char *pkt, size_t pktlen) if (family != AF_INET) break; if (hostent_set_cname(h, rr.rr_dname, 1) == -1) - goto fail; + ; if (hostent_add_addr(h, &rr.rr.in_a.addr, 4) == -1) goto fail; break; @@ -511,7 +511,7 @@ hostent_from_packet(int reqtype, int family, char *pkt, size_t pktlen) if (family != AF_INET6) break; if (hostent_set_cname(h, rr.rr_dname, 1) == -1) - goto fail; + ; if (hostent_add_addr(h, &rr.rr.in_aaaa.addr6, 16) == -1) goto fail; break; |