aboutsummaryrefslogtreecommitdiffstats
path: root/sonar-plugin-api/src/main/java
diff options
context:
space:
mode:
authorSimon Brandhof <simon.brandhof@sonarsource.com>2016-03-24 22:38:16 +0100
committerSimon Brandhof <simon.brandhof@sonarsource.com>2016-03-24 22:38:16 +0100
commit4250bb53f050b5a7f86b211ec2b34f85f7cc3ddc (patch)
tree4c50139f0022fa9adf87173ea9b143c78bc8d1a1 /sonar-plugin-api/src/main/java
parent80d64d20e5fe3980b0057030a35368fc83ba0984 (diff)
downloadsonarqube-4250bb53f050b5a7f86b211ec2b34f85f7cc3ddc.tar.gz
sonarqube-4250bb53f050b5a7f86b211ec2b34f85f7cc3ddc.zip
Fix quality flaws
Diffstat (limited to 'sonar-plugin-api/src/main/java')
-rw-r--r--sonar-plugin-api/src/main/java/org/sonar/api/utils/Duration.java12
1 files changed, 5 insertions, 7 deletions
diff --git a/sonar-plugin-api/src/main/java/org/sonar/api/utils/Duration.java b/sonar-plugin-api/src/main/java/org/sonar/api/utils/Duration.java
index cd397e3df94..554ff4d6a54 100644
--- a/sonar-plugin-api/src/main/java/org/sonar/api/utils/Duration.java
+++ b/sonar-plugin-api/src/main/java/org/sonar/api/utils/Duration.java
@@ -19,15 +19,13 @@
*/
package org.sonar.api.utils;
-import org.apache.commons.lang.StringUtils;
-import org.apache.commons.lang.builder.ToStringBuilder;
-import org.apache.commons.lang.builder.ToStringStyle;
-
-import javax.annotation.Nullable;
-
import java.io.Serializable;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
+import javax.annotation.Nullable;
+import org.apache.commons.lang.StringUtils;
+import org.apache.commons.lang.builder.ToStringBuilder;
+import org.apache.commons.lang.builder.ToStringStyle;
/**
* @since 4.3
@@ -47,7 +45,7 @@ public class Duration implements Serializable {
}
private Duration(int days, int hours, int minutes, int hoursInDay) {
- this((days * hoursInDay * MINUTES_IN_ONE_HOUR) + (hours * MINUTES_IN_ONE_HOUR) + minutes);
+ this(((long) days * hoursInDay * MINUTES_IN_ONE_HOUR) + (hours * MINUTES_IN_ONE_HOUR) + minutes);
}
/**