diff options
author | Arne Chrestin <arne.chrestin@telekom.de> | 2023-02-07 17:39:24 +0100 |
---|---|---|
committer | Arne Chrestin <arne.chrestin@telekom.de> | 2023-02-08 09:20:13 +0100 |
commit | abdebae6d193b8a7d44b5444947af8b954bb7271 (patch) | |
tree | 2888e16404056ac85fd3eda7481af1cb94e16a5f /cps-rest/src/main/java/org/onap | |
parent | f965c8eefcf21ceaeff1be461bc51269e1d36715 (diff) |
Correct calculation of zip archive size for schemaset upload
Correct calculation of zip archive size for schemaset upload
Issue-ID: CPS-1477
Change-Id: I73f97f986a817d423f93a8d922dcd9647b0203ab
Signed-off-by: Arne Chrestin <arne.chrestin@telekom.de>
Diffstat (limited to 'cps-rest/src/main/java/org/onap')
-rw-r--r-- | cps-rest/src/main/java/org/onap/cps/rest/utils/MultipartFileUtil.java | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/cps-rest/src/main/java/org/onap/cps/rest/utils/MultipartFileUtil.java b/cps-rest/src/main/java/org/onap/cps/rest/utils/MultipartFileUtil.java index d5c2b092b0..534077caa6 100644 --- a/cps-rest/src/main/java/org/onap/cps/rest/utils/MultipartFileUtil.java +++ b/cps-rest/src/main/java/org/onap/cps/rest/utils/MultipartFileUtil.java @@ -136,7 +136,7 @@ public class MultipartFileUtil { while ((numberOfBytesRead = zipInputStream.read(buffer, 0, READ_BUFFER_SIZE)) > 0) { byteArrayOutputStream.write(buffer, 0, numberOfBytesRead); totalSizeEntry += numberOfBytesRead; - zipFileSizeValidator.updateTotalSizeArchive(totalSizeEntry); + zipFileSizeValidator.updateTotalSizeArchive(numberOfBytesRead); zipFileSizeValidator.validateCompresssionRatio(totalSizeEntry); } return byteArrayOutputStream.toString(StandardCharsets.UTF_8); |