On 2008 Nov 10, at 19:04, Jason Dusek wrote:

simple exe bytes args        =  do
 (i, o, e, p)            <-  runInteractiveProcess exe args Nothing
Nothing
 hPut i bytes
 s                       <-  hGetContents o
 hClose i
 return s

Yep, that's your problem.  forkIO the hPut.

 Maybe I didn't do enough here -- just wrapping in `forkIO`
 does not seem to actually help.


*sigh* I hate the ghc runtime... it works in ghci, or compiled with - threaded. Otherwise you still get the deadlock because it only switches threads under limited circumstances (garbage collections?) which isn't nearly often enough.

--
brandon s. allbery [solaris,freebsd,perl,pugs,haskell] [EMAIL PROTECTED]
system administrator [openafs,heimdal,too many hats] [EMAIL PROTECTED]
electrical and computer engineering, carnegie mellon university    KF8NH


_______________________________________________
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe

Reply via email to