pull/5066/head
2dust 2024-05-04 13:24:13 +08:00
parent 398dbbd2e5
commit 8d21f9b900
1 changed files with 15 additions and 1 deletions

View File

@ -264,7 +264,21 @@ namespace v2rayN.Handler
private static string GetIpv6(string address)
{
return Utils.IsIpv6(address) ? $"[{address}]" : address;
if (Utils.IsIpv6(address))
{
if (address.StartsWith('[') && address.EndsWith(']'))
{
return address;
}
else
{
return $"[{address}]";
}
}
else
{
return address;
}
}
private static int GetStdTransport(ProfileItem item, string? securityDef, ref Dictionary<string, string> dicQuery)