# | Line 1031 | Line 1031 | public class ForkJoinPool extends Abstra | |
---|---|---|
1031 | break; | |
1032 | } | |
1033 | if (tryPreBlock()) { | |
1034 | < | long last = System.nanoTime(); |
1034 | > | final long deadline = System.nanoTime() + nanos; |
1035 | while (joinMe.status >= 0) { | |
1036 | long millis = TimeUnit.NANOSECONDS.toMillis(nanos); | |
1037 | if (millis <= 0) | |
# | Line 1043 | Line 1043 | public class ForkJoinPool extends Abstra | |
1043 | joinMe.cancelIgnoringExceptions(); | |
1044 | break; | |
1045 | } | |
1046 | < | long now = System.nanoTime(); |
1047 | < | nanos -= now - last; |
1048 | < | last = now; |
1046 | > | nanos = deadline - System.nanoTime(); |
1047 | } | |
1048 | postBlock(); | |
1049 | break; |
– | Removed lines |
+ | Added lines |
< | Changed lines |
> | Changed lines |