[Haskell-cafe] runInteractiveCommand

Sergey Perminov sv.perminov at gmail.com
Mon Apr 9 08:30:33 EDT 2007

I wished to get output of unix commands in haskell code.

So i wrote:
import System.IO
import System.Process

eval :: String -> IO String
eval s = do (_,hOutput,_,hProcess) <- runInteractiveCommand s
           sOutput <- hGetContents hOutput
           waitForProcess hProcess
           return sOutput

'eval' works well if output of evaluated command is less than 64Kb.
If not - 'eval' never ends.

What may cause this problem?
Is it possible to use 'runInteractiveCommand' when command's output
size is longer than 64Kb?

Best regards,
Sergey Perminov

More information about the Haskell-Cafe mailing list