netserver/hedgewars-server.hs
changeset 1403 b8c921ed0f13
parent 1398 29eedf717d0f
child 1461 87e5a6c3882c
equal deleted inserted replaced
1402:c164f215f7d2 1403:b8c921ed0f13
    23 	(cHandle, host, port) <- accept servSock
    23 	(cHandle, host, port) <- accept servSock
    24 	hPutStrLn cHandle "CONNECTED\n"
    24 	hPutStrLn cHandle "CONNECTED\n"
    25 	hFlush cHandle
    25 	hFlush cHandle
    26 	cChan <- atomically newTChan
    26 	cChan <- atomically newTChan
    27 	forkIO $ clientLoop cHandle cChan
    27 	forkIO $ clientLoop cHandle cChan
    28 	atomically $ writeTChan acceptChan (ClientInfo cChan cHandle "" 0 "" False False)
    28 	atomically $ writeTChan acceptChan (ClientInfo cChan cHandle "" 0 "" False False False)
    29 	acceptLoop servSock acceptChan
    29 	acceptLoop servSock acceptChan
    30 
    30 
    31 
    31 
    32 listenLoop :: Handle -> [String] -> TChan [String] -> IO ()
    32 listenLoop :: Handle -> [String] -> TChan [String] -> IO ()
    33 listenLoop handle buf chan = do
    33 listenLoop handle buf chan = do