aboutsummaryrefslogtreecommitdiffstats
path: root/aai-service/provider
diff options
context:
space:
mode:
authorDan Timoney <dtimoney@att.com>2017-09-28 07:20:32 +0000
committerGerrit Code Review <gerrit@onap.org>2017-09-28 07:20:32 +0000
commit2c5d29be34111eb03de70a12429d2a3d3e2ebbc1 (patch)
tree307aafee6af9e5bd9288fed63a0ad11c7e7947e7 /aai-service/provider
parentebe6d0127c2dce4ec0953e2a6fc2e40a27609097 (diff)
parent6dc1f4c1f69f1a02926a0bcc06b812a0c28f3e34 (diff)
Merge "Close the inputstream"
Diffstat (limited to 'aai-service/provider')
-rwxr-xr-xaai-service/provider/src/main/java/org/onap/ccsdk/sli/adaptors/aai/AAIService.java3
1 files changed, 1 insertions, 2 deletions
diff --git a/aai-service/provider/src/main/java/org/onap/ccsdk/sli/adaptors/aai/AAIService.java b/aai-service/provider/src/main/java/org/onap/ccsdk/sli/adaptors/aai/AAIService.java
index 840062e7..d3d57eaa 100755
--- a/aai-service/provider/src/main/java/org/onap/ccsdk/sli/adaptors/aai/AAIService.java
+++ b/aai-service/provider/src/main/java/org/onap/ccsdk/sli/adaptors/aai/AAIService.java
@@ -290,12 +290,11 @@ public class AAIService extends AAIDeclarations implements AAIClient, SvcLogicRe
ctx = SSLContext.getInstance("TLS");
KeyManagerFactory kmf = null;
- try {
+ try (FileInputStream fin = new FileInputStream(keystore_path)){
String def = "SunX509";
String storeType = "PKCS12";
def = KeyStore.getDefaultType();
kmf = KeyManagerFactory.getInstance(KeyManagerFactory.getDefaultAlgorithm());
- FileInputStream fin = new FileInputStream(keystore_path);
String extension = keystore_path.substring(keystore_path.lastIndexOf(".") + 1);
if("JKS".equalsIgnoreCase(extension)) {