asdf
parent
7cf64b433f
commit
c3e1c5dabb
4
Anna.hs
4
Anna.hs
|
@ -154,7 +154,7 @@ anna = rollcall
|
|||
write :: String -> String -> Net ()
|
||||
write cmd args = do
|
||||
h <- asks socket
|
||||
liftIO $ hPutStr h $ output
|
||||
liftIO $ hPutStr h output
|
||||
liftIO $ putStr $ "> " ++ output
|
||||
where output = cmd ++ " " ++ args ++ "\r\n"
|
||||
|
||||
|
@ -174,7 +174,7 @@ joinChannels :: Net ()
|
|||
joinChannels = mapM_ (\chn -> write "JOIN" chn) channels
|
||||
|
||||
pong :: Net ()
|
||||
pong = write "PONG" $ ":" ++ name ++ "\r\n"
|
||||
pong = write "PONG" $ ":" ++ name
|
||||
|
||||
-- Connect to a server given its name and port number
|
||||
connectTo :: N.HostName -> N.PortNumber -> IO Handle
|
||||
|
|
Loading…
Reference in New Issue