# HG changeset patch # User unc0rr # Date 1267883125 0 # Node ID 55d272e34f9a08a740290caaa224629495e257c2 # Parent 098eaa7fd88b8377b64248650ce876603b993549 Fix sending routine diff -r 098eaa7fd88b -r 55d272e34f9a gameServer/ClientIO.hs --- a/gameServer/ClientIO.hs Sat Mar 06 13:41:06 2010 +0000 +++ b/gameServer/ClientIO.hs Sat Mar 06 13:45:25 2010 +0000 @@ -35,9 +35,9 @@ answer <- readChan chan doClose <- Exception.handle (\(e :: Exception.IOException) -> if isQuit answer then return True else sendQuit e >> return False) $ do - B.hPutStrLn handle $ BUTF8.fromString $ unlines (answer ++ [""]) - hFlush handle - return $ isQuit answer + B.hPutStrLn handle $ BUTF8.fromString $ unlines answer + hFlush handle + return $ isQuit answer if doClose then Exception.handle (\(_ :: Exception.IOException) -> putStrLn "error on hClose") $ hClose handle