NO-JIRA: Trivial fix for Artemis class, reported by coverity.com

This commit is contained in:
Clebert Suconic 2017-05-05 14:55:44 -04:00
parent a5ea22e8a5
commit c253aa65bf
1 changed files with 10 additions and 6 deletions

View File

@ -179,6 +179,7 @@ public class Artemis {
}
private static long copy(InputStream in, OutputStream out) throws Exception {
try {
byte[] buffer = new byte[1024];
int len = in.read(buffer);
while (len != -1) {
@ -186,6 +187,9 @@ public class Artemis {
len = in.read(buffer);
}
return len;
} finally {
in.close();
}
}
}