Fix incorrect formatting of URL with IPv6 brackets

This commit is contained in:
klzgrad 2022-07-01 22:03:06 +08:00
parent c9a374fbde
commit 71c67d5347

View File

@ -247,7 +247,7 @@ int NaiveConnection::DoConnectServer() {
url::CanonHostInfo host_info;
url::SchemeHostPort endpoint(
"http", CanonicalizeHost(origin.host(), &host_info), origin.port(),
"http", CanonicalizeHost(origin.HostForURL(), &host_info), origin.port(),
url::SchemeHostPort::ALREADY_CANONICALIZED);
if (!endpoint.IsValid()) {
LOG(ERROR) << "Connection " << id_ << " to invalid origin " << origin.ToString();