|
|
| Perl: the Markov chain saw | |
| PerlMonks |
Re: Backticks and SIGALRMby dwm042 (Priest) |
| on Aug 20, 2007 at 13:17 UTC ( #633811=note: print w/ replies, xml ) | Need Help?? |
|
I've seen similar issues in shell scripting, and the solution I settled on was similar to what moritz is suggesting. We opened a FIFO queue, forked the process into a parent and child. The child launched the unreliable app, and helped funnel the output into the FIFO. Parent would read the FIFO and also set a timer. If the child lived longer than the time set on the timer, the child process was killed.
In Section
Seekers of Perl Wisdom
|
|
||||||||||||||||||||