On 2009 Jan 22, at 3:11, Belka wrote:
Actually, I'm more interested in technical details how to
communicate from
shell with background process - how to send commands to it. Currently
looking into POSIX libraries hope to find answers there...
Also, maybe a FIFO-pipe-file would solve my problem. Imagine writing a
command in it, while one of daemon's thread is locked-while-awaits for
anything to come out from the other side of the pipe...
You can try it; make sure to open the FIFO for read+write to avoid
deadlocks, and I think there are some weird behaviors caused by the
GHC runtime's non-blocking IO. It will be a lot easier to use a
socket (AF_INET or AF_UNIX depending on whether you want to support
remote access or not).
--
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
[email protected]
http://www.haskell.org/mailman/listinfo/haskell-cafe