Check if the filedes of kevent is expected one. Though our

old resolver opened just one socket, BIND9's resolver may
open more than one sockets.  And, BIND9's resolver doesn't
close the socket on timeout.  So, we need this check.

Reported by:	freebsd-cvs-src__at__oldach.net (Helge Oldach), bz
Hinted by:	rwatson
This commit is contained in:
Hajimu UMEMOTO 2006-08-04 12:26:07 +00:00
parent 0e0b1bb57a
commit 45c89f1e05

View File

@ -970,6 +970,10 @@ send_dg(res_state statp,
res_nclose(statp);
return (0);
}
#ifdef USE_KQUEUE
if (kv.ident != s)
goto wait;
#endif
errno = 0;
fromlen = sizeof(from);
resplen = _recvfrom(s, (char*)ans, anssiz,0,