Skip to content
This repository has been archived by the owner on Apr 22, 2021. It is now read-only.

Commit

Permalink
Fix: NullPointerException triggered when http error in job allocation (
Browse files Browse the repository at this point in the history
  • Loading branch information
luguina authored Jul 7, 2020
1 parent 081c20f commit 674a375
Showing 1 changed file with 9 additions and 4 deletions.
13 changes: 9 additions & 4 deletions src/com/sheepit/client/Server.java
Original file line number Diff line number Diff line change
Expand Up @@ -475,11 +475,16 @@ else if (this.client.getRenderingJob().isUserBlockJob()) {
}
finally {
try {
output.flush();
output.close();
is.close();
if (output != null) {
output.flush();
output.close();
}

if (is != null) {
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()));
}
}
Expand Down

0 comments on commit 674a375

Please sign in to comment.