mirror of
https://github.com/3proxy/3proxy.git
synced 2025-02-23 10:35:40 +08:00
Correct typo (name resolution could fail on some platforms)
This commit is contained in:
parent
dd75eaa35e
commit
1fd759d327
@ -911,7 +911,7 @@ unsigned long getip46(int family, unsigned char *name, struct sockaddr *sa){
|
||||
|
||||
detect = afdetect(name);
|
||||
if(detect != -1){
|
||||
if(family == 4 && detect != 4) return 0;
|
||||
if(family == 4 && detect != AF_INET) return 0;
|
||||
*SAFAMILY(sa) = (family == 6)? AF_INET6 : detect;
|
||||
return inet_pton(*SAFAMILY(sa), (char *)name, SAADDR(sa))? *SAFAMILY(sa) : 0;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user