<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Tue, Jun 30, 2015 at 2:27 PM, Hiromi ISHII <span dir="ltr"><<a href="mailto:konn.jinro@gmail.com" target="_blank">konn.jinro@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div id=":u3" class="a3s" style="overflow:hidden">quickCheck* functions writes results to stderr & stdout, but I<br>
don't want them written to the app's original stdout/err.<br>
(I'm using SafeHaskell features to avoid malicious code executed,<br>
so don't worry about that :-))<br>
<br>
So I want to execute I/O action hijacking stdout/err in a thread-safe manner.<br>
For example, I need function like below:<br></div></blockquote></div><br>Handles are process level, not thread level, in all supported operating systems. If something is writing to stderr then it is writing to a process level entity and there is no way to capture it at the level of a thread.<br clear="all"><div><br></div>-- <br><div class="gmail_signature"><div dir="ltr"><div>brandon s allbery kf8nh sine nomine associates</div><div><a href="mailto:allbery.b@gmail.com" target="_blank">allbery.b@gmail.com</a> <a href="mailto:ballbery@sinenomine.net" target="_blank">ballbery@sinenomine.net</a></div><div>unix, openafs, kerberos, infrastructure, xmonad <a href="http://sinenomine.net" target="_blank">http://sinenomine.net</a></div></div></div>
</div></div>