X-Git-Url: http://git.cielonegro.org/gitweb.cgi?a=blobdiff_plain;f=Network%2FHTTP%2FLucu%2FHttpd.hs;h=ac1dc77a66379508ac8f1bf2c0528c1f2ddd037a;hb=3baf479eba12bc3e9c4ef966df770cd70aa5cd81;hp=e1abcab63d8fc5344262f3cde0f14eec136347b8;hpb=01fe22bec14421e3b9430efbfc9daee05f181730;p=Lucu.git diff --git a/Network/HTTP/Lucu/Httpd.hs b/Network/HTTP/Lucu/Httpd.hs index e1abcab..ac1dc77 100644 --- a/Network/HTTP/Lucu/Httpd.hs +++ b/Network/HTTP/Lucu/Httpd.hs @@ -48,8 +48,8 @@ import Prelude.Unicode -- > } -- -- FIXME: update the above example -runHttpd ∷ Config → SchemeMap → IO () -runHttpd cnf sm +runHttpd ∷ HostMapper α ⇒ Config → α → IO () +runHttpd cnf hm = do let launchers = catMaybes [ do addr ← cnfServerV4Addr cnf @@ -108,7 +108,7 @@ runHttpd cnf sm httpLoop port so = do (h, addr) ← SL.accept so tQueue ← mkInteractionQueue - readerTID ← forkIO $ requestReader cnf sm h port addr tQueue + readerTID ← forkIO $ requestReader cnf hm h port addr tQueue _writerTID ← forkIO $ responseWriter cnf h tQueue readerTID httpLoop port so