6751021: TEST_BUG: race condition in the test java/lang/Runtime/exec/Duped.java
authormichaelm
Thu, 03 Feb 2011 12:57:04 +0000
changeset 8170 2042acb02807
parent 8169 0dc88a086893
child 8171 71793028dd76
6751021: TEST_BUG: race condition in the test java/lang/Runtime/exec/Duped.java Reviewed-by: alanb
jdk/test/java/lang/Runtime/exec/Duped.java
--- a/jdk/test/java/lang/Runtime/exec/Duped.java	Thu Feb 03 11:56:56 2011 +0000
+++ b/jdk/test/java/lang/Runtime/exec/Duped.java	Thu Feb 03 12:57:04 2011 +0000
@@ -38,8 +38,7 @@
         public static void main(String args[]) throws Exception {
             StringBuffer s = new StringBuffer();
             int c;
-            while ((System.in.available() != 0)
-                           && ((c = System.in.read()) != -1))
+            while ((c = System.in.read()) != -1)
                 s.append((char)c);
             System.out.println(s);
         }