X-Git-Url: http://git.cielonegro.org/gitweb.cgi?p=Lucu.git;a=blobdiff_plain;f=Network%2FHTTP%2FLucu%2FHttpd.hs;h=595403abd0364f1a2e70c79088d9138d38eeaf90;hp=2dca5120d8c6e0e21f40b88a03959d4017c848d4;hb=f402841101b4b84f263eea1a43c848f81c48ff93;hpb=0aa4f6d758fc12fba468f7cd399bbcc48f693d1e diff --git a/Network/HTTP/Lucu/Httpd.hs b/Network/HTTP/Lucu/Httpd.hs index 2dca512..595403a 100644 --- a/Network/HTTP/Lucu/Httpd.hs +++ b/Network/HTTP/Lucu/Httpd.hs @@ -45,7 +45,7 @@ import System.Posix.Signals -- > helloWorld :: ResourceDef -- > helloWorld = emptyResource { -- > resGet --- > = Just $ do setContentType $ mkMIMEType "text" "plain" +-- > = Just $ do setContentType $ parseMIMEType "text/plain" -- > putChunk "Hello, world!" -- > } runHttpd ∷ Config → ResTree → [FallbackHandler] → IO () @@ -105,7 +105,7 @@ runHttpd cnf tree fbs httpLoop ∷ SocketLike s ⇒ PortNumber → s → IO () httpLoop port so = do (h, addr) ← SL.accept so - tQueue ← newInteractionQueue + tQueue ← mkInteractionQueue readerTID ← forkIO $ requestReader cnf tree fbs h port addr tQueue _writerTID ← forkIO $ responseWriter cnf h tQueue readerTID httpLoop port so