mirror of
https://github.com/3proxy/3proxy.git
synced 2025-02-23 10:35:40 +08:00
Prevent too fast connections on connect back
Prevent to fast connections on connect back proxy if port is not reachable
This commit is contained in:
parent
a9ec5a085c
commit
c538d0c2f8
@ -532,11 +532,13 @@ int MODULEMAINFUNC (int argc, char** argv){
|
||||
if(so._connect(new_sock,(struct sockaddr *)&defparam.sincr,sizeof(defparam.sincr))) {
|
||||
so._closesocket(new_sock);
|
||||
new_sock = INVALID_SOCKET;
|
||||
usleep(SLEEPTIME);
|
||||
continue;
|
||||
}
|
||||
if(so._recvfrom(new_sock,buf,1,0,(struct sockaddr*)&defparam.sincr, &size) != 1) {
|
||||
so._closesocket(new_sock);
|
||||
new_sock = INVALID_SOCKET;
|
||||
usleep(SLEEPTIME);
|
||||
continue;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user