Pass 2 pipes to each thread? set the second pipe as reader in the thread and writer in the main thread. Probably you would have to stuff the pipe filehandles in a hash in the main thread, so you could keep track of which pipe writes to which thread. I suppose you can run IO::Select in each thread to watch for messages, or setup an eventloop to watch the filehandle, or a basic loop of some sort.
I will work on an example. :-)
In reply to Re^2: Using Select and pipes to communicate with threads
by zentara
in thread Using Select and pipes to communicate with threads
by zentara
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |