X-Git-Url: http://www.project-moonshot.org/gitweb/?a=blobdiff_plain;f=udp.c;h=c804703ae8f6ae50343c250b40360f66b2d88136;hb=883992d876f34a0486e675160a60701dc0a1b66a;hp=4740fd0830f785fecdb5c864cc264de885329b89;hpb=eff1f8d633fa2b07396e1d1f82043823d6916ba2;p=libradsec.git diff --git a/udp.c b/udp.c index 4740fd0..c804703 100644 --- a/udp.c +++ b/udp.c @@ -24,9 +24,9 @@ #include #include #include -#include "list.h" -#include "hostport.h" +#include #include "radsecproxy.h" +#include "hostport.h" #ifdef RADPROT_UDP #include "debug.h" @@ -86,7 +86,9 @@ static char **getlistenerargs() { void udpsetsrcres() { if (!srcres) - srcres = resolvepassiveaddrinfo(protoopts ? protoopts->sourcearg : NULL, NULL, protodefs.socktype); + srcres = + resolvepassiveaddrinfo(protoopts ? protoopts->sourcearg : NULL, + AF_UNSPEC, NULL, protodefs.socktype); } void removeudpclientfromreplyq(struct client *c) { @@ -318,6 +320,7 @@ void addclientudp(struct client *client) { } void addserverextraudp(struct clsrvconf *conf) { + assert(list_first(conf->hostports) != NULL); switch (((struct hostportres *)list_first(conf->hostports)->data)->addrinfo->ai_family) { case AF_INET: if (client4_sock < 0) {