Skip to content

Commit

Permalink
[FIXED JENKINS-26264] UpdateUpdater perform will throw an AbortExcept…
Browse files Browse the repository at this point in the history
…ion instead of returning null
  • Loading branch information
tastatur committed Jan 18, 2015
1 parent a20e047 commit e5ef893
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/main/java/hudson/scm/subversion/UpdateUpdater.java
Expand Up @@ -26,6 +26,7 @@
*/
package hudson.scm.subversion;

import hudson.AbortException;
import hudson.Extension;
import hudson.model.Hudson;
import hudson.scm.SubversionSCM.External;
Expand Down Expand Up @@ -167,7 +168,7 @@ public List<External> perform() throws IOException, InterruptedException {
} catch (SVNCancelException e) {
if (isAuthenticationFailedError(e)) {
e.printStackTrace(listener.error("Failed to check out " + location.remote));
return null;
throw (AbortException) new AbortException().initCause(e);

This comment has been minimized.

Copy link
@KostyaSha

KostyaSha Jun 29, 2015

Member

Looks weird, AbortException designed for not throwing stacktrace. If you want it, then just throw e and it will be printed to listener.

} else {
listener.error("Subversion update has been canceled");
throw (InterruptedException)new InterruptedException().initCause(e);
Expand Down

0 comments on commit e5ef893

Please sign in to comment.