mirror of
https://github.com/3proxy/3proxy.git
synced 2025-02-23 18:45:40 +08:00
Fixed handling of [] IPv6 addresses in hostnames
This commit is contained in:
parent
271d9bb91a
commit
74772de341
@ -250,7 +250,7 @@ int parsehostname(char *hostname, struct clientparam *param, unsigned short port
|
|||||||
if(sp){
|
if(sp){
|
||||||
port = atoi(sp+1);
|
port = atoi(sp+1);
|
||||||
}
|
}
|
||||||
getip46(param->srv->family, param->hostname + (se!=0), (struct sockaddr *)¶m->req);
|
getip46(param->srv->family, param->hostname, (struct sockaddr *)¶m->req);
|
||||||
if(se) *se = ']';
|
if(se) *se = ']';
|
||||||
if(sp) *sp = ':';
|
if(sp) *sp = ':';
|
||||||
*SAPORT(¶m->req) = htons(port);
|
*SAPORT(¶m->req) = htons(port);
|
||||||
|
Loading…
Reference in New Issue
Block a user