diff options
author | Gao Weitao <victor.gao@huawei.com> | 2017-09-20 09:43:25 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@onap.org> | 2017-09-20 09:43:25 +0000 |
commit | 2407600251db0ab82627e9177031b0cfcc4fedf4 (patch) | |
tree | 849a8e9bbad9f14bf68568d0880da0753b54f2f3 | |
parent | eaee3ceffd38a09c8b217a7b47dcfdaba2dc5f1c (diff) | |
parent | c8ef69f735803f6ed19dd9ab4387ce725a2cf439 (diff) |
Merge "Remove the useless judgement"
2 files changed, 3 insertions, 6 deletions
diff --git a/huawei/vnfmadapter/VnfmadapterService/service/src/main/java/org/onap/vfc/nfvo/vnfm/svnfm/vnfmadapter/common/DownloadCsarManager.java b/huawei/vnfmadapter/VnfmadapterService/service/src/main/java/org/onap/vfc/nfvo/vnfm/svnfm/vnfmadapter/common/DownloadCsarManager.java index b2157ed9..66d3b650 100644 --- a/huawei/vnfmadapter/VnfmadapterService/service/src/main/java/org/onap/vfc/nfvo/vnfm/svnfm/vnfmadapter/common/DownloadCsarManager.java +++ b/huawei/vnfmadapter/VnfmadapterService/service/src/main/java/org/onap/vfc/nfvo/vnfm/svnfm/vnfmadapter/common/DownloadCsarManager.java @@ -96,6 +96,7 @@ public class DownloadCsarManager { is.close(); fileout.flush(); fileout.close(); + client.close(); status = Constant.DOWNLOADCSAR_SUCCESS; } catch(Exception e) { diff --git a/huawei/vnfmadapter/VnfmadapterService/service/src/main/java/org/onap/vfc/nfvo/vnfm/svnfm/vnfmadapter/service/adapter/impl/AdapterResourceManager.java b/huawei/vnfmadapter/VnfmadapterService/service/src/main/java/org/onap/vfc/nfvo/vnfm/svnfm/vnfmadapter/service/adapter/impl/AdapterResourceManager.java index f9fe98f5..13765a88 100644 --- a/huawei/vnfmadapter/VnfmadapterService/service/src/main/java/org/onap/vfc/nfvo/vnfm/svnfm/vnfmadapter/service/adapter/impl/AdapterResourceManager.java +++ b/huawei/vnfmadapter/VnfmadapterService/service/src/main/java/org/onap/vfc/nfvo/vnfm/svnfm/vnfmadapter/service/adapter/impl/AdapterResourceManager.java @@ -596,12 +596,8 @@ public class AdapterResourceManager implements IResourceManager { if(fileContent != null) { jsonObject = JSONObject.fromObject(fileContent).getJSONObject("vnfdIds"); } - if(ins != null) { - ins.close(); - } - if(bins != null) { - bins.close(); - } + ins.close(); + bins.close(); } catch(Exception e) { LOG.error(fileName + " read error!", e); } finally { |