Skip to content
Permalink
Browse files

[JENKINS-42556] Handle runtime exceptions from printWaitingMessage.

  • Loading branch information...
jglick committed Mar 9, 2017
1 parent 6fce277 commit 3c076a7c93717ee7d819eeda82dd91f1be099bde
@@ -26,6 +26,7 @@

import com.google.common.util.concurrent.AbstractFuture;
import com.google.common.util.concurrent.ListenableFuture;
import hudson.Functions;
import hudson.console.ModelHyperlinkNote;
import hudson.model.TaskListener;
import java.io.IOException;
@@ -92,7 +93,12 @@ public void run() {
if (v == null) {
if (retriesRemaining == 0) {
try {
printWaitingMessage(getOwner().getListener());
TaskListener listener = getOwner().getListener();
try {
printWaitingMessage(listener);
} catch (Exception x) {
listener.getLogger().println(Functions.printThrowable(x).trim()); // TODO 2.43+ use Functions.printStackTrace
}
} catch (IOException x) {
LOGGER.log(Level.WARNING, null, x);
}

0 comments on commit 3c076a7

Please sign in to comment.
You can’t perform that action at this time.