Browse Source

Merge 1.9.x branch into master

master
Jaikiran Pai 6 years ago
parent
commit
87b252f740
1 changed files with 3 additions and 2 deletions
  1. +3
    -2
      src/main/org/apache/tools/ant/taskdefs/AugmentReference.java

+ 3
- 2
src/main/org/apache/tools/ant/taskdefs/AugmentReference.java View File

@@ -17,6 +17,7 @@
*/
package org.apache.tools.ant.taskdefs;

import org.apache.tools.ant.BuildException;
import org.apache.tools.ant.Project;
import org.apache.tools.ant.RuntimeConfigurable;
import org.apache.tools.ant.Task;
@@ -48,7 +49,7 @@ public class AugmentReference extends Task implements TypeAdapter {
log("project reference " + id + "=" + String.valueOf(result), Project.MSG_DEBUG);
return result;
}
throw new IllegalStateException("Unknown reference \"" + id + "\"");
throw new BuildException("Unknown reference \"" + id + "\"");
}

/**
@@ -63,7 +64,7 @@ public class AugmentReference extends Task implements TypeAdapter {
RuntimeConfigurable wrapper = getWrapper();
id = wrapper.getId();
if (id == null) {
throw new IllegalStateException(getTaskName() + " attribute 'id' unset");
throw new BuildException(getTaskName() + " attribute 'id' unset");
}
wrapper.setAttribute("id", null);
wrapper.removeAttribute("id");


Loading…
Cancel
Save