Commit 14552817ac11c87276bb12afc3125b4d9557fb76

Thomas de Grivel 2024-09-14T19:56:34

fix httpd

diff --git a/lib/kc3/0.1/httpd.kc3 b/lib/kc3/0.1/httpd.kc3
index 9014a2f..ef4fb0e 100644
--- a/lib/kc3/0.1/httpd.kc3
+++ b/lib/kc3/0.1/httpd.kc3
@@ -47,6 +47,8 @@ defmodule HTTPd do
           "Connection", "Keep-Alive")
         response = HTTP.Response.set_header(response,
           "Keep-Alive", "timeout=5, max=1000")
+        response = HTTP.Response.set_header(response,
+          "Server", "kc3_httpd")
         r = HTTP.Response.buf_write(response, client.buf_rw.w,
           req.method != HEAD)
         client_addr = if client.addr_str != "127.0.0.1" do
@@ -64,7 +66,7 @@ defmodule HTTPd do
     end
   end
 
-  def timeout = %Time{tv_sec: 5}
+  def timeout = %Time{tv_sec: (Sw) 5}
 
   def acceptor = fn (server_socket, events, acceptor_ev, void) do
     if List.has?(events, :read) do