Remove race condition in TestStart JEP-349-branch
authoregahlin
Fri, 23 Aug 2019 13:30:12 +0200
branchJEP-349-branch
changeset 57857 d957ea28ed21
parent 57848 bd961c64ecce
child 57858 9254b05c141c
Remove race condition in TestStart
test/jdk/jdk/jfr/api/consumer/recordingstream/TestStart.java
--- a/test/jdk/jdk/jfr/api/consumer/recordingstream/TestStart.java	Thu Aug 22 20:36:52 2019 +0200
+++ b/test/jdk/jdk/jfr/api/consumer/recordingstream/TestStart.java	Fri Aug 23 13:30:12 2019 +0200
@@ -125,8 +125,8 @@
                     rs.start(); // must not deadlock
                 } catch (IllegalStateException ise) {
                     if (!ISE.get())  {
+                        ISE.set(true);
                         startedTwice.countDown();
-                        ISE.set(true);
                     }
                 }
             });