Navigation Menu

Skip to content

Commit

Permalink
[FIXED JENKINS-9203] mark the build as failure by using the new API
Browse files Browse the repository at this point in the history
  • Loading branch information
kohsuke committed Aug 27, 2011
1 parent 7485913 commit 36c0385
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion pom.xml
Expand Up @@ -3,7 +3,7 @@
<parent>
<groupId>org.jenkins-ci.plugins</groupId>
<artifactId>plugin</artifactId>
<version>1.398</version>
<version>1.420</version>
</parent>

<artifactId>build-timeout</artifactId>
Expand Down
Expand Up @@ -7,6 +7,7 @@
import hudson.model.BuildListener;
import hudson.model.Descriptor;
import hudson.model.Executor;
import hudson.model.Result;
import hudson.tasks.BuildWrapper;
import hudson.tasks.BuildWrapperDescriptor;
import hudson.triggers.SafeTimerTask;
Expand Down Expand Up @@ -62,7 +63,7 @@ public void doRun() {
timeout=true;
Executor e = build.getExecutor();
if (e != null)
e.interrupt();
e.interrupt(failBuild? Result.FAILURE : Result.ABORTED);
}
}

Expand Down

0 comments on commit 36c0385

Please sign in to comment.