1 package nmp.file_utils; 2 3 import java.io.*; 4 import java.lang.reflect.*; 5 6 7 public class LogSysExecute 8 { 9 public static void main( String[] args) { 10 try { 11 String[] newargs = new String[args.length - 2]; 12 for( int i = 2; i < args.length; i++) 13 newargs[i-2] = args[i]; 14 System.setOut( new PrintStream( new FileOutputStream( args[0]))); 15 System.setErr( new PrintStream( new FileOutputStream( args[1]))); 16 Runtime.getRuntime().exec( newargs); 17 } catch( Throwable th) { 18 th.printStackTrace(); 19 } 20 } 21 }

This page was automatically generated by Maven