|
[ ghc-Bugs-1187302 ] runProcess doesn't close handles?: msg#00101lang.haskell.glasgow.bugs
Bugs item #1187302, was opened at 2005-04-21 11:24 Message generated for change (Tracker Item Submitted) made by Item Submitter You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=108032&aid=1187302&group_id=8032 Category: libraries/base Group: 6.4 Status: Open Resolution: None Priority: 5 Submitted By: Roman Leshchinskiy (romanle) Assigned to: Nobody/Anonymous (nobody) Summary: runProcess doesn't close handles? Initial Comment: The documentation for runProcess says: "Any Handles passed to runProcess are placed immediately in the closed state, so may no longer be referenced by the Haskell process." But test = do h <- openFile "output" WriteMode ph <- runProcess "/bin/ls" [] Nothing Nothing Nothing (Just h) Nothing waitForProcess ph main = test >> test >> return () aborts with "output: openFile: resource busy (file is locked)" on the second call to test whereas test = do h <- openFile "output" WriteMode ph <- runProcess "/bin/ls" [] Nothing Nothing Nothing (Just h) Nothing hClose h waitForProcess ph main = test >> test >> return () works fine. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=108032&aid=1187302&group_id=8032
|
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | [ ghc-Bugs-1187295 ] runProcess hangs with duplicate handles, SourceForge.net |
|---|---|
| Next by Date: | [ ghc-Bugs-1188155 ] Bootstrapping fails at System/CPUTime_hsc.c, SourceForge.net |
| Previous by Thread: | [ ghc-Bugs-1187295 ] runProcess hangs with duplicate handles, SourceForge.net |
| Next by Thread: | [ ghc-Bugs-1188155 ] Bootstrapping fails at System/CPUTime_hsc.c, SourceForge.net |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
| News | FAQ | advertise |