waitFor() causes the current thread to block and wait for the Process to finish.
If you want to read the output of the process, you use the streams from the Process:
Process.getOutputStream();// stdout for the process
Process.getInputStream(); // stdin for the process
Process.getErrorStream(); // stderr for the process
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.