exec and waitFor()
843798Dec 11 2001 — edited Feb 14 2002Greetings.
I run the Runtime.exec() command with a relatively long (240 chars +) command on NT. When I run this command from Java and do a waitFor() on the process it blocks forever. This supposedly indicates the process is not over and/or the application is not responding. However, when I run the same command from the command line it works fine - implies application is fine.
However, when I reduce the length of the command (reduce the path length of the i/p files etc) it works fine.
From what I see, there seems to be a problem with the length of the command sent via rt.exec(). Is this true? Is there a way around this problem?