Lines Matching defs:ex
168 #define WILD_AF(ex) ((ex)->e_wild & 0x01)
169 #define WILD_SOCKTYPE(ex) ((ex)->e_wild & 0x02)
170 #define WILD_PROTOCOL(ex) ((ex)->e_wild & 0x04)
601 const struct explore *ex;
646 for (ex = explore; ex->e_af >= 0; ex++) {
647 if (pai->ai_family != ex->e_af)
649 if (ex->e_socktype == ANY)
651 if (ex->e_protocol == ANY)
653 if (pai->ai_socktype == ex->e_socktype
654 && pai->ai_protocol != ex->e_protocol) {
690 for (ex = explore; ex->e_af >= 0; ex++) {
694 if (ex->e_af == PF_UNSPEC)
697 if (!MATCH_FAMILY(pai->ai_family, ex->e_af, WILD_AF(ex)))
699 if (!MATCH(pai->ai_socktype, ex->e_socktype, WILD_SOCKTYPE(ex)))
701 if (!MATCH(pai->ai_protocol, ex->e_protocol, WILD_PROTOCOL(ex)))
705 pai->ai_family = ex->e_af;
706 if (pai->ai_socktype == ANY && ex->e_socktype != ANY)
707 pai->ai_socktype = ex->e_socktype;
708 if (pai->ai_protocol == ANY && ex->e_protocol != ANY)
709 pai->ai_protocol = ex->e_protocol;
750 for (ex = explore; ex->e_af >= 0; ex++) {
754 if (pai->ai_family != ex->e_af)
757 if (!MATCH(pai->ai_socktype, ex->e_socktype,
758 WILD_SOCKTYPE(ex))) {
761 if (!MATCH(pai->ai_protocol, ex->e_protocol,
762 WILD_PROTOCOL(ex))) {
766 if (pai->ai_socktype == ANY && ex->e_socktype != ANY)
767 pai->ai_socktype = ex->e_socktype;
768 if (pai->ai_protocol == ANY && ex->e_protocol != ANY)
769 pai->ai_protocol = ex->e_protocol;