git-svn-id: https://svn.apache.org/repos/asf/ant/core/trunk@275058 13f79535-47bb-0310-9956-ffa450edef68master
| @@ -509,14 +509,14 @@ public class AntClassLoader extends ClassLoader implements BuildListener { | |||||
| public String getClasspath() { | public String getClasspath() { | ||||
| StringBuffer sb = new StringBuffer(); | StringBuffer sb = new StringBuffer(); | ||||
| boolean firstPass = true; | boolean firstPass = true; | ||||
| Enumeration enum = pathComponents.elements(); | |||||
| while (enum.hasMoreElements()) { | |||||
| Enumeration componentEnum = pathComponents.elements(); | |||||
| while (componentEnum.hasMoreElements()) { | |||||
| if (!firstPass) { | if (!firstPass) { | ||||
| sb.append(System.getProperty("path.separator")); | sb.append(System.getProperty("path.separator")); | ||||
| } else { | } else { | ||||
| firstPass = false; | firstPass = false; | ||||
| } | } | ||||
| sb.append(((File) enum.nextElement()).getAbsolutePath()); | |||||
| sb.append(((File) componentEnum.nextElement()).getAbsolutePath()); | |||||
| } | } | ||||
| return sb.toString(); | return sb.toString(); | ||||
| } | } | ||||
| @@ -528,10 +528,10 @@ public class ComponentHelper { | |||||
| synchronized (createdTasks) { | synchronized (createdTasks) { | ||||
| Vector v = (Vector) createdTasks.get(type); | Vector v = (Vector) createdTasks.get(type); | ||||
| if (v != null) { | if (v != null) { | ||||
| Enumeration enum = v.elements(); | |||||
| while (enum.hasMoreElements()) { | |||||
| Enumeration taskEnum = v.elements(); | |||||
| while (taskEnum.hasMoreElements()) { | |||||
| WeakishReference ref = | WeakishReference ref = | ||||
| (WeakishReference) enum.nextElement(); | |||||
| (WeakishReference) taskEnum.nextElement(); | |||||
| Task t = (Task) ref.get(); | Task t = (Task) ref.get(); | ||||
| //being a weak ref, it may be null by this point | //being a weak ref, it may be null by this point | ||||
| if (t != null) { | if (t != null) { | ||||