title: Process Builder Issue
body: <p>I am working on a java program where I have to call another java program using process builder because it uses a separate JRE. </p>
  
  <p>Here is batch program which calls this program and works properly:</p>
  
  <pre><code>cd C:\apps\Project_name\bin\
  C:\Progra~1\Java\jre1.6.0_03\bin\java -Xms512m -Xmx1024m
       -cp ../lib/spring-1.2.2.jar;../lib/log4j-1.2.8.jar;../lib/commons-logging-1.0.4.jar;../lib/wrapper.jar
       com.project.main.MainProgramLauncher arg1 arg2
  </code></pre>
  
  <p>Now I declared my code something like this:</p>
  
  <pre><code>ProcessBuilder builder = new ProcessBuilder(
      "java",
      "-Xms512m",
      "-Xmx1024m",
      "-cp ../lib/spring-1.2.2.jar;../lib/log4j-1.2.8.jar;"+
      "../lib/commons-logging-1.0.4.jar;../lib/wrapper.jar",
      "com.project.main.MainProgramLauncher arg1 arg2 ...argN"
  );
  Map&lt;String, String&gt; environment = builder.environment();
  
  environment.put("path", ";"); // Clearing the path variable;
  environment.put("path", java_bin_location+";");
  Process javap = builder.start();
  InputStreamReader tempReader = new InputStreamReader(
      new BufferedInputStream(javap.getInputStream())
  );
  BufferedReader reader = new BufferedReader(tempReader);
  while (true) {
      String line = reader.readLine();
      if (line == null)
          break;
      System.out.println(line);
  }
  </code></pre>
  
  <p>But its not executing the way it should be. The program crashing right away. Is there anything different I should be doing? Please suggest.</p>