Skip to content

Commit

Permalink
[JENKINS-36871] Stop complaining when the channel is already closed
Browse files Browse the repository at this point in the history
  • Loading branch information
stephenc committed Aug 3, 2016
1 parent d2504bc commit 0ef5cac
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/main/java/hudson/remoting/Channel.java
Expand Up @@ -1154,6 +1154,10 @@ public synchronized void close(Throwable diagnosis) throws IOException {

try {
send(new CloseCommand(this, diagnosis));
} catch (ChannelClosedException e) {
logger.log(Level.FINEST, "Channel is already closed", e);
terminate(e);
return;
} catch (IOException e) {
// send should only ever - worst case - throw an IOException so we'll just catch that and not Throwable
logger.log(Level.WARNING, "Having to terminate early", e);
Expand Down

0 comments on commit 0ef5cac

Please sign in to comment.