阅读背景:

Runtime.getRuntime.exec()适用于Windows但不适用于Linux

来源:互联网 

I am building a Java application that calls a system command and executes that command before returning control to the Java thread. The debugging step that I have is that I have made a perl script called test.pl and I call that script from the Java method and in Windows I get the expected output and a return value of 0. In Linux I get no output or error output and I get a return value of 136. I have spent extensive time online trying to figure out where I have gone wrong but as I have said, on Windows it runs. I think it must be a simple error that I am just not catching.I am building a Java application that calls a s




你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: