diff options
-rw-r--r-- | Cargo.lock | 2 | ||||
-rw-r--r-- | Cargo.toml | 2 | ||||
-rw-r--r-- | src/main.rs | 6 |
3 files changed, 5 insertions, 5 deletions
@@ -32,7 +32,7 @@ dependencies = [ [[package]] name = "ipaddrsrv" -version = "0.1.0" +version = "0.1.1" dependencies = [ "ctrlc", ] @@ -1,6 +1,6 @@ [package] name = "ipaddrsrv" -version = "0.1.0" +version = "0.1.1" edition = "2024" [dependencies] diff --git a/src/main.rs b/src/main.rs index ffa1892..3c03b46 100644 --- a/src/main.rs +++ b/src/main.rs @@ -78,13 +78,13 @@ impl ConnectionSettings { } } if conn.state == 4 { - // 90B is more than long enough for our response + // 128B is more than long enough for our response write!( - &mut buffer[..90], + &mut buffer[..128], "HTTP/1.1 200 OK\r\nContent-Type: text/plain\r\n\r\n{addr}\n\0" ) .expect("?? writing address to buffer failed??"); - let length = buffer[..90] + let length = buffer[..128] .iter() .position(|&c| c == 0) .expect("?? no null byte even though we just wrote one??"); |