F
Ferenc Engard
Hi all,
Is there a simple way to spawn an external program, feed its stdin, and
get its stdout?
The problem with popen is, if I want to feed a few MB's of input to it,
then it hangs (I suspect that its stdout IO buffer is full) before I
could read out its stdout on the next line. So, the following do not
work:
io=IO.popen("externalfilter")
io.write(verybigstring)
result=io.read
Thanks,
Ferenc
Is there a simple way to spawn an external program, feed its stdin, and
get its stdout?
The problem with popen is, if I want to feed a few MB's of input to it,
then it hangs (I suspect that its stdout IO buffer is full) before I
could read out its stdout on the next line. So, the following do not
work:
io=IO.popen("externalfilter")
io.write(verybigstring)
result=io.read
Thanks,
Ferenc