From 302a84f4b4b51f5e288e4371600d0b373b488932 Mon Sep 17 00:00:00 2001 From: rrr-marble Date: Thu, 14 Oct 2021 14:32:07 +0300 Subject: [PATCH] fix: accept any http protocol version --- src/main.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main.rs b/src/main.rs index a913679..b8fa36d 100644 --- a/src/main.rs +++ b/src/main.rs @@ -17,7 +17,7 @@ fn handle_connection(mut stream: TcpStream) { let mut buffer = [0; 1024]; stream.read(&mut buffer).unwrap(); - let get = b"GET / HTTP/1.1\r\n"; + let get = b"GET / HTTP"; let (status_line, contents) = if buffer.starts_with(get) { (