Fix: NullPointerException triggered when http error in job allocation (#274)

This commit is contained in:
Luis Uguina
2020-07-07 23:38:23 +10:00
committed by GitHub
parent e4be013505
commit 4dba9ebf94

View File

@@ -475,11 +475,16 @@ public class Server extends Thread {
} }
finally { finally {
try { try {
if (output != null) {
output.flush(); output.flush();
output.close(); output.close();
}
if (is != null) {
is.close(); is.close();
} }
catch (IOException e) { }
catch (Exception e) {
this.log.debug(String.format("Server::HTTPGetFile Error trying to close the open streams (%s)", e.getMessage())); this.log.debug(String.format("Server::HTTPGetFile Error trying to close the open streams (%s)", e.getMessage()));
} }
} }