Merge remote-tracking branch 'refs/remotes/origin/devel'

This commit is contained in:
z3APA3A 2016-01-17 02:14:16 +03:00
commit e5dd28003c
2 changed files with 3 additions and 3 deletions

View File

@ -1113,7 +1113,7 @@ unsigned long udpresolve(int af, unsigned char * name, unsigned char * value, un
continue; continue;
} }
if(param) param->statscli64 += len; if(param) param->statscli64 += len;
len = sockrecvfrom(sock, sinsr, buf, 4096, 15000); len = sockrecvfrom(sock, sinsr, buf, 4096, conf.timeouts[DNS_TO]*1000);
so._shutdown(sock, SHUT_RDWR); so._shutdown(sock, SHUT_RDWR);
so._closesocket(sock); so._closesocket(sock);
if(len <= 13) { if(len <= 13) {
@ -1125,7 +1125,7 @@ unsigned long udpresolve(int af, unsigned char * name, unsigned char * value, un
us = ntohs(*(unsigned short*)buf); us = ntohs(*(unsigned short*)buf);
len-=2; len-=2;
buf+=2; buf+=2;
if(us > 4096 || us < len || (us > len && sockrecvfrom(sock, sinsr, buf+len, us-len, 15000) != us-len)) { if(us > 4096 || us < len || (us > len && sockrecvfrom(sock, sinsr, buf+len, us-len, conf.timeouts[DNS_TO]*1000) != us-len)) {
continue; continue;
} }
} }

View File

@ -158,7 +158,7 @@ void * dnsprchild(struct clientparam* param) {
} }
param->statscli64 += i; param->statscli64 += i;
param->nwrites++; param->nwrites++;
len = sockrecvfrom(param->remsock, (struct sockaddr *)&param->sinsr, buf, BUFSIZE, 15000); len = sockrecvfrom(param->remsock, (struct sockaddr *)&param->sinsr, buf, BUFSIZE, conf.timeouts[DNS_TO]*1000);
if(len <= 13) { if(len <= 13) {
RETURN(821); RETURN(821);
} }