[
https://issues.apache.org/jira/browse/KNOX-748?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15459581#comment-15459581
]
Hadoop QA commented on KNOX-748:
--------------------------------
Testing JIRA KNOX-748
Patch
[KNOX-748.001.patch|https://issues.apache.org/jira/secure/attachment/12826743/KNOX-748.001.patch]
downloaded at Fri Sep 2 20:22:25 UTC 2016
----------------------------
{color:green}+1 PATCH_APPLIES{color}
{color:green}+1 CLEAN{color}
{color:red}-1 RAW_PATCH_ANALYSIS{color}
. {color:green}+1{color} the patch does not introduce any @author tags
. {color:green}+1{color} the patch does not introduce any tabs
. {color:green}+1{color} the patch does not introduce any trailing spaces
. {color:green}+1{color} the patch does not introduce any line longer than
120
. {color:red}-1{color} the patch does not add/modify any testcase
{color:green}+1 RAT{color}
. {color:green}+1{color} the patch does not seem to introduce new RAT
warnings
{color:green}+1 JAVADOC{color}
. {color:green}+1{color} the patch does not seem to introduce new Javadoc
warnings
{color:green}+1 COMPILE{color}
. {color:green}+1{color} HEAD compiles
. {color:green}+1{color} patch compiles
. {color:green}+1{color} the patch does not seem to introduce new javac
warnings
. {color:red}WARNING{color}: the current HEAD has 76 javac warning(s)
{color:green}+1 FINDBUGS{color}
. {color:green}+1{color} the patch does not seem to introduce new Findbugs
warnings
. {color:red}WARNING: the current HEAD has Findbugs warning(s), they should
be addressed ASAP{color}
{color:green}+1 TESTS{color}
. Tests run: 664
{color:green}+1 DISTRO{color}
. {color:green}+1{color} distro tarball builds with the patch
----------------------------
{color:red}*-1 Overall result, please check the reported -1(s)*{color}
{color:red}. There is at least one warning, please check{color}
The full output of the test-patch run is available at
. https://builds.apache.org/job/Knox-master-patch-verify/73/
> Fix Resource Leak in X509CertificateUtil.writeCertificateToJKS
> --------------------------------------------------------------
>
> Key: KNOX-748
> URL: https://issues.apache.org/jira/browse/KNOX-748
> Project: Apache Knox
> Issue Type: Bug
> Components: Server
> Reporter: Larry McCay
> Assignee: Sandeep More
> Fix For: 0.10.0
>
> Attachments: KNOX-748.001.patch
>
>
> New defect(s) Reported-by: Coverity Scan
> Showing 1 of 1 defect(s)
> ** CID 1361992: Exceptional resource leaks (RESOURCE_LEAK)
> /gateway-spi/src/main/java/org/apache/hadoop/gateway/services/security/impl/X509CertificateUtil.java:
> 299 in
> org.apache.hadoop.gateway.services.security.impl.X509CertificateUtil.writeCertificateToJKS(java.security.cert.Certificate,
> java.io.File)()
> ________________________________________________________________________________________________________
> *** CID 1361992: Exceptional resource leaks (RESOURCE_LEAK)
> /gateway-spi/src/main/java/org/apache/hadoop/gateway/services/security/impl/X509CertificateUtil.java:
> 299 in
> org.apache.hadoop.gateway.services.security.impl.X509CertificateUtil.writeCertificateToJKS(java.security.cert.Certificate,
> java.io.File)()
> 293
> 294 char[] password = "changeme".toCharArray();
> 295 ks.load(null, password);
> 296 ks.setCertificateEntry("gateway-identity", cert);
> 297
> 298 FileOutputStream fos = new FileOutputStream(file);
> CID 1361992: Exceptional resource leaks (RESOURCE_LEAK)
> Variable "fos" going out of scope leaks the resource it refers to.
> 299 ks.store(fos, password);
> 300 fos.close();
> 301 }
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)