LSPcalc是一个exe ...后跟一些参数。这个过程永远不会回来。
Process procs = Runtime.getRuntime().exec(new String[]{"./LSPcalc","U",SN,Penalty});
System.out.println("Done initializing LSPcalc");
StreamReaderThread stdout1 = new StreamReaderThread(procs.getInputStream(), "OUT");
StreamReaderThread stderr1 = new StreamReaderThread(procs.getErrorStream(), "ERR");
try{
stdout1.start();
stderr1.start();
procs.waitFor();
stdout1.join();
stderr1.join();
}catch(InterruptedException ie){
ie.printStackTrace();
}