mirror of
https://github.com/cytopia/devilbox.git
synced 2024-12-19 21:07:53 +00:00
Fix IPv6 handling
This commit is contained in:
parent
10571f7b51
commit
025b45c48c
@ -214,11 +214,10 @@ class Httpd extends BaseClass implements BaseInterface
|
||||
|
||||
$type = $arr[1];
|
||||
$prot = $arr[2];
|
||||
$addr = '';
|
||||
$addr = ''; // this may contain ':' itself due to IPv6 addresses
|
||||
for ($i=3; $i<(count($arr)-1); $i++) {
|
||||
$addr .= $arr[$i];
|
||||
}
|
||||
$addr = $arr[3]; // this may contain ':' itself
|
||||
$port = $arr[count($arr) - 1];
|
||||
|
||||
return $prot.'://'.$addr.':'.$port;
|
||||
|
Loading…
Reference in New Issue
Block a user