|
@@ -357,11 +357,11 @@ public abstract class Task extends ProjectComponent { |
|
|
*/ |
|
|
*/ |
|
|
public final void perform() { |
|
|
public final void perform() { |
|
|
if (!invalid) { |
|
|
if (!invalid) { |
|
|
|
|
|
getProject().fireTaskStarted(this); |
|
|
|
|
|
Throwable reason = null; |
|
|
try { |
|
|
try { |
|
|
getProject().fireTaskStarted(this); |
|
|
|
|
|
maybeConfigure(); |
|
|
maybeConfigure(); |
|
|
execute(); |
|
|
execute(); |
|
|
getProject().fireTaskFinished(this, null); |
|
|
|
|
|
} catch (RuntimeException exc) { |
|
|
} catch (RuntimeException exc) { |
|
|
if (exc instanceof BuildException) { |
|
|
if (exc instanceof BuildException) { |
|
|
BuildException be = (BuildException) exc; |
|
|
BuildException be = (BuildException) exc; |
|
@@ -369,8 +369,10 @@ public abstract class Task extends ProjectComponent { |
|
|
be.setLocation(getLocation()); |
|
|
be.setLocation(getLocation()); |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
getProject().fireTaskFinished(this, exc); |
|
|
|
|
|
|
|
|
reason = exc; |
|
|
throw exc; |
|
|
throw exc; |
|
|
|
|
|
} finally { |
|
|
|
|
|
getProject().fireTaskFinished(this, reason); |
|
|
} |
|
|
} |
|
|
} else { |
|
|
} else { |
|
|
UnknownElement ue = getReplacement(); |
|
|
UnknownElement ue = getReplacement(); |
|
|