Thursday, April 1, 2004 03:43 PM
From the sounds of the javadoc, exec returns a Process object that maps to an underlying subprocess
ie. a separate thread for each system process.
So each Process object returned is separate, therefore process.getInputStream() in each Java thread will be talking to a different Process object, and won't interfere!
If you're really worried, wrap the call to exec in a synchronized block.