[FIXED JENKINS-9203] in light of 9c965617b3, I think the proper fix is to define a mechanism to abort with status.

This commit is contained in:
Kohsuke Kawaguchi committed 2011-06-17 11:26:46 -07:00
1 parent df5862c97c
commit a3354b12cf
10 files changed
+62 -8

No files matched your search

@@ -43,6 +43,7 @@ import hudson.model.BuildListener;
import hudson.model.Cause.UpstreamCause;
import hudson.model.Computer;
import hudson.model.Environment;
import hudson.model.Executor;
import hudson.model.Fingerprint;
import jenkins.model.Jenkins;
import hudson.model.ParameterDefinition;
@@ -746,7 +747,7 @@ public class MavenModuleSetBuild extends AbstractMavenBuild<MavenModuleSet,Maven
}
}
} catch (InterruptedException e) {
r = ABORTED;
r = Executor.currentExecutor().abortResult();
throw e;
} finally {
if (r != null) {
@@ -771,7 +772,7 @@ public class MavenModuleSetBuild extends AbstractMavenBuild<MavenModuleSet,Maven
return Result.FAILURE;
} catch (InterruptedIOException e) {
e.printStackTrace(listener.error("Aborted Maven execution for InterruptedIOException"));
return Result.ABORTED;
return Executor.currentExecutor().abortResult();
} catch (IOException e) {
e.printStackTrace(listener.error(Messages.MavenModuleSetBuild_FailedToParsePom()));
return Result.FAILURE;