jdk/test/java/io/PrintStream/OversynchronizedTest.java
changeset 32649 2ee9017c7597
parent 30046 cf2c86e1819e
equal deleted inserted replaced
32648:1fa861caf840 32649:2ee9017c7597
    85         //the following line might cause hang if there is System.out.println(testObj)
    85         //the following line might cause hang if there is System.out.println(testObj)
    86         //called by other threads.
    86         //called by other threads.
    87         System.out.println("In test().");
    87         System.out.println("In test().");
    88     }
    88     }
    89 
    89 
    90     synchronized public String toString() {
    90     public synchronized String toString() {
    91         System.out.println("Calling toString\n");
    91         System.out.println("Calling toString\n");
    92         return mStr;
    92         return mStr;
    93     }
    93     }
    94 }
    94 }