Skip to content

Commit 737c8ae

Browse files
move host header to h1 client
1 parent d285f15 commit 737c8ae

File tree

1 file changed

+0
-9
lines changed

1 file changed

+0
-9
lines changed

src/client.rs

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -65,15 +65,6 @@ pub async fn encode(req: Request) -> Result<Encoder, std::io::Error> {
6565
log::trace!("> {}", &val);
6666
buf.write_all(val.as_bytes()).await?;
6767

68-
let val = format!(
69-
"Host: {}\r\n",
70-
req.url()
71-
.host_str()
72-
.ok_or_else(|| io::Error::new(io::ErrorKind::Other, "Missing hostname"))?
73-
);
74-
log::trace!("> {}", &val);
75-
buf.write_all(val.as_bytes()).await?;
76-
7768
// If the body isn't streaming, we can set the content-length ahead of time. Else we need to
7869
// send all items in chunks.
7970
if let Some(len) = req.len() {

0 commit comments

Comments
 (0)