diff options
author | Simon Brandhof <simon.brandhof@sonarsource.com> | 2014-10-14 21:47:34 +0200 |
---|---|---|
committer | Simon Brandhof <simon.brandhof@sonarsource.com> | 2014-10-14 21:47:34 +0200 |
commit | c809056c115524c9303c5b9c8e77964d976d4226 (patch) | |
tree | 22e770f6cf31f2d03a830eab04c6508a4c27f17a /sonar-batch | |
parent | 3f74239a8255ad897c43b0b2fd260003b083eac9 (diff) | |
download | sonarqube-c809056c115524c9303c5b9c8e77964d976d4226.tar.gz sonarqube-c809056c115524c9303c5b9c8e77964d976d4226.zip |
Fix quality flaws
Diffstat (limited to 'sonar-batch')
-rw-r--r-- | sonar-batch/src/main/java/org/sonar/batch/design/BaseTangleIndexDecorator.java | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/sonar-batch/src/main/java/org/sonar/batch/design/BaseTangleIndexDecorator.java b/sonar-batch/src/main/java/org/sonar/batch/design/BaseTangleIndexDecorator.java index 509cedcc7f1..069b5707236 100644 --- a/sonar-batch/src/main/java/org/sonar/batch/design/BaseTangleIndexDecorator.java +++ b/sonar-batch/src/main/java/org/sonar/batch/design/BaseTangleIndexDecorator.java @@ -82,9 +82,8 @@ public class BaseTangleIndexDecorator implements Decorator { return context.getMeasure(tangleIndexMetric) == null; } - private double compute(double tangles, double totalWeight) { - if (totalWeight==0.0) { + if (Double.doubleToRawLongBits(totalWeight) == 0L) { return 0.0; } double result = 2 * tangles / totalWeight; |