You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by ah...@apache.org on 2021/07/14 14:23:57 UTC

[commons-rng] 03/23: spotbugs: use consistent synchronization

This is an automated email from the ASF dual-hosted git repository.

aherbert pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/commons-rng.git

commit eb880e9734aed8856d07154161518033bd93fda3
Author: aherbert <ah...@apache.org>
AuthorDate: Wed Jul 14 13:35:21 2021 +0100

    spotbugs: use consistent synchronization
---
 .../java/org/apache/commons/rng/examples/stress/StressTestCommand.java  | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/commons-rng-examples/examples-stress/src/main/java/org/apache/commons/rng/examples/stress/StressTestCommand.java b/commons-rng-examples/examples-stress/src/main/java/org/apache/commons/rng/examples/stress/StressTestCommand.java
index c8de0bf..2321a43 100644
--- a/commons-rng-examples/examples-stress/src/main/java/org/apache/commons/rng/examples/stress/StressTestCommand.java
+++ b/commons-rng-examples/examples-stress/src/main/java/org/apache/commons/rng/examples/stress/StressTestCommand.java
@@ -610,7 +610,7 @@ class StressTestCommand implements Callable<Void> {
          *
          * @param total The total tasks.
          */
-        void setTotal(int total) {
+        synchronized void setTotal(int total) {
             this.total = total;
             startTimes = new long[total];
             sortedDurations = new long[total];