Fix bug - cast as long 53/116953/1
authorPamela Dragosh <pdragosh@research.att.com>
Mon, 18 Jan 2021 13:48:54 +0000 (08:48 -0500)
committerPamela Dragosh <pdragosh@research.att.com>
Mon, 18 Jan 2021 13:49:02 +0000 (08:49 -0500)
Sonar wants to promote one value to a long, to avoid risk of overflow before assignment.

Issue-ID: POLICY-2908
Change-Id: I2a92cfd8e437dac3f77ee0366993ae28b2c4c05e
Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
plugins/reception-plugins/src/main/java/org/onap/policy/distribution/reception/decoding/policy/file/PolicyDecoderFileInCsarToPolicy.java

index 1e04b93..4703725 100644 (file)
@@ -48,7 +48,7 @@ public class PolicyDecoderFileInCsarToPolicy implements PolicyDecoder<Csar, Tosc
 
     private PolicyDecoderFileInCsarToPolicyParameterGroup decoderParameters;
     private StandardCoder coder;
-    private static final long MAX_FILE_SIZE = 512 * 1024;
+    private static final long MAX_FILE_SIZE = 512L * 1024;
 
     /**
      * {@inheritDoc}.