You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by gg...@apache.org on 2020/08/05 16:20:36 UTC
[commons-crypto] branch master updated: Remove compiler warning and
document.
This is an automated email from the ASF dual-hosted git repository.
ggregory pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/commons-crypto.git
The following commit(s) were added to refs/heads/master by this push:
new 7d5ce81 Remove compiler warning and document.
7d5ce81 is described below
commit 7d5ce81abec1585c72e89660b7698e1096b00603
Author: Gary Gregory <ga...@gmail.com>
AuthorDate: Wed Aug 5 12:20:28 2020 -0400
Remove compiler warning and document.
---
src/main/java/org/apache/commons/crypto/stream/CryptoOutputStream.java | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/src/main/java/org/apache/commons/crypto/stream/CryptoOutputStream.java b/src/main/java/org/apache/commons/crypto/stream/CryptoOutputStream.java
index 343f5eb..94bcd53 100644
--- a/src/main/java/org/apache/commons/crypto/stream/CryptoOutputStream.java
+++ b/src/main/java/org/apache/commons/crypto/stream/CryptoOutputStream.java
@@ -99,7 +99,7 @@ public class CryptoOutputStream extends OutputStream implements
* @param params the algorithm parameters.
* @throws IOException if an I/O error occurs.
*/
-
+ @SuppressWarnings("resource") // The CryptoCipher returned by getCipherInstance() is closed by CryptoOutputStream.
public CryptoOutputStream(final String transformation,
final Properties props, final OutputStream out, final Key key,
final AlgorithmParameterSpec params) throws IOException {
@@ -122,6 +122,7 @@ public class CryptoOutputStream extends OutputStream implements
* @param params the algorithm parameters.
* @throws IOException if an I/O error occurs.
*/
+ @SuppressWarnings("resource") // The CryptoCipher returned by getCipherInstance() is closed by CryptoOutputStream.
public CryptoOutputStream(final String transformation,
final Properties props, final WritableByteChannel out, final Key key,
final AlgorithmParameterSpec params) throws IOException {