We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 57acdc1 commit 695bc04Copy full SHA for 695bc04
src/async_impl/h3_client/connect.rs
@@ -47,7 +47,11 @@ impl H3Connector {
47
}
48
49
pub async fn connect(&mut self, dest: Uri) -> Result<H3Connection, BoxError> {
50
- let host = dest.host().ok_or("destination must have a host")?;
+ let host = dest
51
+ .host()
52
+ .ok_or("destination must have a host")?
53
+ .trim_start_matches('[')
54
+ .trim_end_matches(']');
55
let port = dest.port_u16().unwrap_or(443);
56
57
let addrs = if let Some(addr) = IpAddr::from_str(host).ok() {
0 commit comments