RFR: 6703075: (process) java/lang/ProcessBuilder/Basic.java fails with fastdebug

Rob McKenna rob.mckenna at oracle.com
Tue Nov 19 21:41:55 UTC 2013


Great, thanks Martin. I totally overlooked that flag while hunting 
around globals.hpp. I've added your contribution here:

http://cr.openjdk.java.net/~robm/6703075/webrev.02/

     -Rob

On 19/11/13 19:58, Martin Buchholz wrote:
> I propose a fix like the diff below, that asks the VM to separate 
> regular output and JVM output into stdout and stderr, so that we can 
> do matching on each independently, and so that we can rely on stdout 
> not being corrupted by JVM output.
>
> @@ -555,9 +555,10 @@
>          System.getProperty("java.class.path");
>      private static final List<String> javaChildArgs =
> -        Arrays.asList(new String[]
> -            { javaExe, "-classpath", absolutifyPath(classpath),
> -              "Basic$JavaChild"});
> +        Arrays.asList(javaExe,
> +                      "-XX:+DisplayVMOutputToStderr",
> +                      "-classpath", absolutifyPath(classpath),
> +                      "Basic$JavaChild");
>      private static void testEncoding(String encoding, String tested) {
>          try {
> @@ -1593,8 +1594,8 @@
>                                        javaExe));
>              list.add("ArrayOOME");
>              ProcessResults r = run(new ProcessBuilder(list));
> -  check(r.out().contains("java.lang.OutOfMemoryError:"));
> -            check(r.out().contains(javaExe));
> +  check(r.err().contains("java.lang.OutOfMemoryError:"));
> +            check(r.err().contains(javaExe));
>  check(r.err().contains(System.getProperty("java.version")));
>              equal(r.exitValue(), 1);
>          } catch (Throwable t) { unexpected(t); }
>
>
>
> On Tue, Nov 19, 2013 at 11:29 AM, Martin Buchholz <martinrb at google.com 
> <mailto:martinrb at google.com>> wrote:
>
>     Hold on - I'll try to get you alternate fix.
>
>
>     On Tue, Nov 19, 2013 at 11:27 AM, Alan Bateman
>     <Alan.Bateman at oracle.com <mailto:Alan.Bateman at oracle.com>> wrote:
>
>         On 19/11/2013 16:46, Rob McKenna wrote:
>
>             Hi folks,
>
>             Running this test with fastdebug binaries results in a few
>             warning messages getting lumped into the commandOutput.
>             I've decided to filter these test wide.
>
>             https://bugs.openjdk.java.net/browse/JDK-6703075
>             http://cr.openjdk.java.net/~robm/6703075/webrev.01/
>             <http://cr.openjdk.java.net/%7Erobm/6703075/webrev.01/>
>
>                 -Rob
>
>         Having warning messages emitted by the VM and interfering with
>         application or test output is annoying. What you have is okay
>         for now but perhaps there is an option to redirect them to
>         elsewhere.
>
>         -Alan
>
>
>




More information about the core-libs-dev mailing list