logo       

runInteractiveProcess, confused: msg#00075

lang.haskell.glasgow.bugs

Subject: runInteractiveProcess, confused

Hi,

When I run the following line in ghci:

Prelude System.Process Control.Concurrent System.IO> do { (inp, out, err, ph)
<- runInteractiveProcess "cat" [] Nothing Nothing; forkIO (do hPutStr inp
"this\nis\na\ntest\n"; hClose inp); waitForProcess ph }

... it doesn't terminate. I'm following the example in the
System.Process documentation. But I would think that since I close
'inp', "cat" would terminate. Also, I don't see the expected output.

Frederik

--
http://ofb.net/~frederik/


<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

News | FAQ | advertise