bodewig 2004/11/12 07:17:12 Modified: src/main/org/apache/tools/ant Project.java src/main/org/apache/tools/ant/filters TokenFilter.java src/main/org/apache/tools/ant/filters/util ChainReaderHelper.java src/main/org/apache/tools/ant/helper ProjectHelperImpl.java src/main/org/apache/tools/ant/taskdefs AntStructure.java Definer.java Delete.java ExecTask.java Execute.java Exit.java FixCRLF.java Javac.java Javadoc.java MacroInstance.java Property.java Replace.java SubAnt.java Tar.java Untar.java WhichResource.java XSLTProcess.java src/main/org/apache/tools/ant/taskdefs/rmic WLRmic.java src/main/org/apache/tools/ant/types AbstractFileSet.java CommandlineJava.java EnumeratedAttribute.java FilterSet.java Mapper.java PropertySet.java src/main/org/apache/tools/ant/types/selectors DateSelector.java ExtendSelector.java SizeSelector.java TypeSelector.java src/main/org/apache/tools/ant/types/selectors/modifiedselector ModifiedSelector.java src/main/org/apache/tools/bzip2 CBZip2InputStream.java src/main/org/apache/tools/tar TarEntry.java TarInputStream.java src/main/org/apache/tools/zip ZipOutputStream.java Log: Make Jikes happy Revision Changes Path 1.178 +4 -4 ant/src/main/org/apache/tools/ant/Project.java Index: Project.java =================================================================== RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/Project.java,v retrieving revision 1.177 retrieving revision 1.178 diff -u -r1.177 -r1.178 --- Project.java 10 Nov 2004 00:37:30 -0000 1.177 +++ Project.java 12 Nov 2004 15:14:58 -0000 1.178 @@ -830,9 +830,9 @@ Properties systemP = System.getProperties(); Enumeration e = systemP.propertyNames(); while (e.hasMoreElements()) { - String name = (String) e.nextElement(); - String value = systemP.getProperty(name); - this.setPropertyInternal(name.toString(), value); + String propertyName = (String) e.nextElement(); + String value = systemP.getProperty(propertyName); + this.setPropertyInternal(propertyName, value); } } 1.19 +1 -3 ant/src/main/org/apache/tools/ant/filters/TokenFilter.java Index: TokenFilter.java =================================================================== RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/filters/TokenFilter.java,v retrieving revision 1.18 retrieving revision 1.19 diff -u -r1.18 -r1.19 --- TokenFilter.java 18 May 2004 08:14:49 -0000 1.18 +++ TokenFilter.java 12 Nov 2004 15:14:59 -0000 1.19 @@ -21,7 +21,6 @@ import java.util.Vector; import java.util.Enumeration; import org.apache.tools.ant.BuildException; -import org.apache.tools.ant.Project; import org.apache.tools.ant.ProjectComponent; import org.apache.tools.ant.types.RegularExpression; import org.apache.tools.ant.types.Substitution; @@ -645,7 +644,6 @@ public static class ContainsRegex extends ChainableReaderFilter { private String from; private String to; - private Project project; private RegularExpression regularExpression; private Substitution substitution; private boolean initialized = false; @@ -685,7 +683,7 @@ } regularExpression = new RegularExpression(); regularExpression.setPattern(from); - regexp = regularExpression.getRegexp(project); + regexp = regularExpression.getRegexp(getProject()); if (to == null) { return; } 1.25 +2 -2 ant/src/main/org/apache/tools/ant/filters/util/ChainReaderHelper.java Index: ChainReaderHelper.java =================================================================== RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/filters/util/ChainReaderHelper.java,v retrieving revision 1.24 retrieving revision 1.25 diff -u -r1.24 -r1.25 --- ChainReaderHelper.java 10 Nov 2004 00:37:31 -0000 1.24 +++ ChainReaderHelper.java 12 Nov 2004 15:14:59 -0000 1.25 @@ -138,7 +138,7 @@ = (AntFilterReader) finalFilters.elementAt(i); final String className = filter.getClassName(); final Path classpath = filter.getClasspath(); - final Project project = filter.getProject(); + final Project pro = filter.getProject(); if (className != null) { try { Class clazz = null; @@ -146,7 +146,7 @@ clazz = Class.forName(className); } else { AntClassLoader al - = project.createClassLoader(classpath); + = pro.createClassLoader(classpath); clazz = Class.forName(className, true, al); } if (clazz != null) { 1.28 +5 -5 ant/src/main/org/apache/tools/ant/helper/ProjectHelperImpl.java Index: ProjectHelperImpl.java =================================================================== RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/helper/ProjectHelperImpl.java,v retrieving revision 1.27 retrieving revision 1.28 diff -u -r1.27 -r1.28 --- ProjectHelperImpl.java 9 Mar 2004 16:48:03 -0000 1.27 +++ ProjectHelperImpl.java 12 Nov 2004 15:14:59 -0000 1.28 @@ -103,12 +103,12 @@ throw new BuildException("Only File source supported by " + "default plugin"); } - File buildFile = (File) source; + File bFile = (File) source; FileInputStream inputStream = null; InputSource inputSource = null; this.project = project; - this.buildFile = new File(buildFile.getAbsolutePath()); + this.buildFile = new File(bFile.getAbsolutePath()); buildFileParent = new File(this.buildFile.getParent()); try { @@ -119,11 +119,11 @@ } - String uri = fu.toURI(buildFile.getAbsolutePath()); - inputStream = new FileInputStream(buildFile); + String uri = fu.toURI(bFile.getAbsolutePath()); + inputStream = new FileInputStream(bFile); inputSource = new InputSource(inputStream); inputSource.setSystemId(uri); - project.log("parsing buildfile " + buildFile + " with URI = " + project.log("parsing buildfile " + bFile + " with URI = " + uri, Project.MSG_VERBOSE); HandlerBase hb = new RootHandler(this); parser.setDocumentHandler(hb); 1.42 +6 -6 ant/src/main/org/apache/tools/ant/taskdefs/AntStructure.java Index: AntStructure.java =================================================================== RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/AntStructure.java,v retrieving revision 1.41 retrieving revision 1.42 diff -u -r1.41 -r1.42 --- AntStructure.java 9 Mar 2004 16:48:03 -0000 1.41 +++ AntStructure.java 12 Nov 2004 15:14:59 -0000 1.42 @@ -102,9 +102,9 @@ Enumeration tasks = getProject().getTaskDefinitions().keys(); while (tasks.hasMoreElements()) { - String taskName = (String) tasks.nextElement(); - printElementDecl(out, taskName, - (Class) getProject().getTaskDefinitions().get(taskName)); + String tName = (String) tasks.nextElement(); + printElementDecl(out, tName, + (Class) getProject().getTaskDefinitions().get(tName)); } } catch (IOException ioe) { @@ -131,13 +131,13 @@ out.print("<!ENTITY % tasks \""); boolean first = true; while (tasks.hasMoreElements()) { - String taskName = (String) tasks.nextElement(); + String tName = (String) tasks.nextElement(); if (!first) { out.print(" | "); } else { first = false; } - out.print(taskName); + out.print(tName); } out.println("\">"); out.print("<!ENTITY % types \""); 1.56 +3 -3 ant/src/main/org/apache/tools/ant/taskdefs/Definer.java Index: Definer.java =================================================================== RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/Definer.java,v retrieving revision 1.55 retrieving revision 1.56 diff -u -r1.55 -r1.56 --- Definer.java 20 Oct 2004 08:38:04 -0000 1.55 +++ Definer.java 12 Nov 2004 15:14:59 -0000 1.56 @@ -214,12 +214,12 @@ while (urls.hasMoreElements()) { URL url = (URL) urls.nextElement(); - int format = this.format; + int fmt = this.format; if (url.toString().toLowerCase(Locale.US).endsWith(".xml")) { - format = Format.XML; + fmt = Format.XML; } - if (format == Format.PROPERTIES) { + if (fmt == Format.PROPERTIES) { loadProperties(al, url); break; } else { 1.55 +5 -5 ant/src/main/org/apache/tools/ant/taskdefs/Delete.java Index: Delete.java =================================================================== RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/Delete.java,v retrieving revision 1.54 retrieving revision 1.55 diff -u -r1.54 -r1.55 --- Delete.java 10 Jun 2004 07:44:10 -0000 1.54 +++ Delete.java 12 Nov 2004 15:14:59 -0000 1.55 @@ -642,13 +642,13 @@ if (dirs.length > 0 && includeEmpty) { int dirCount = 0; for (int j = dirs.length - 1; j >= 0; j--) { - File dir = new File(d, dirs[j]); - String[] dirFiles = dir.list(); + File currDir = new File(d, dirs[j]); + String[] dirFiles = currDir.list(); if (dirFiles == null || dirFiles.length == 0) { - log("Deleting " + dir.getAbsolutePath(), verbosity); - if (!delete(dir)) { + log("Deleting " + currDir.getAbsolutePath(), verbosity); + if (!delete(currDir)) { String message = "Unable to delete directory " - + dir.getAbsolutePath(); + + currDir.getAbsolutePath(); if (failonerror) { throw new BuildException(message); } else { 1.74 +2 -2 ant/src/main/org/apache/tools/ant/taskdefs/ExecTask.java Index: ExecTask.java =================================================================== RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/ExecTask.java,v retrieving revision 1.73 retrieving revision 1.74 diff -u -r1.73 -r1.74 --- ExecTask.java 21 Oct 2004 10:31:06 -0000 1.73 +++ ExecTask.java 12 Nov 2004 15:14:59 -0000 1.74 @@ -416,8 +416,8 @@ } if (p == null) { - Vector env = Execute.getProcEnvironment(); - Enumeration e = env.elements(); + Vector envVars = Execute.getProcEnvironment(); + Enumeration e = envVars.elements(); while (e.hasMoreElements()) { String line = (String) e.nextElement(); if (isPath(line)) { 1.85 +5 -5 ant/src/main/org/apache/tools/ant/taskdefs/Execute.java Index: Execute.java =================================================================== RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/Execute.java,v retrieving revision 1.84 retrieving revision 1.85 diff -u -r1.84 -r1.85 --- Execute.java 6 Oct 2004 22:41:52 -0000 1.84 +++ Execute.java 12 Nov 2004 15:14:59 -0000 1.85 @@ -535,10 +535,10 @@ } }; - ExecuteStreamHandler streamHandler = new PumpStreamHandler(dummyOut); - streamHandler.setProcessErrorStream(process.getErrorStream()); - streamHandler.setProcessOutputStream(process.getInputStream()); - streamHandler.start(); + ExecuteStreamHandler handler = new PumpStreamHandler(dummyOut); + handler.setProcessErrorStream(process.getErrorStream()); + handler.setProcessOutputStream(process.getInputStream()); + handler.start(); process.getOutputStream().close(); project.log("spawned process " + process.toString(), Project.MSG_VERBOSE); 1.35 +2 -1 ant/src/main/org/apache/tools/ant/taskdefs/Exit.java Index: Exit.java =================================================================== RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/Exit.java,v retrieving revision 1.34 retrieving revision 1.35 diff -u -r1.34 -r1.35 --- Exit.java 20 Sep 2004 20:22:51 -0000 1.34 +++ Exit.java 12 Nov 2004 15:14:59 -0000 1.35 @@ -17,6 +17,7 @@ package org.apache.tools.ant.taskdefs; +import org.apache.tools.ant.Project; import org.apache.tools.ant.Task; import org.apache.tools.ant.BuildException; import org.apache.tools.ant.ExitStatusException; @@ -136,7 +137,7 @@ } } } - log("failing due to " + text, getProject().MSG_DEBUG); + log("failing due to " + text, Project.MSG_DEBUG); throw ((status == null) ? new BuildException(text) : new ExitStatusException(text, status.intValue())); } 1.61 +8 -8 ant/src/main/org/apache/tools/ant/taskdefs/FixCRLF.java Index: FixCRLF.java =================================================================== RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/FixCRLF.java,v retrieving revision 1.60 retrieving revision 1.61 diff -u -r1.60 -r1.61 --- FixCRLF.java 9 Mar 2004 16:48:04 -0000 1.60 +++ FixCRLF.java 12 Nov 2004 15:14:59 -0000 1.61 @@ -574,12 +574,12 @@ */ private void nextStateChange(OneLiner.BufferLine bufline) throws BuildException { - int eol = bufline.length(); + int eofl = bufline.length(); int ptr = bufline.getNext(); // Look for next single or double quote, double slash or slash star - while (ptr < eol) { + while (ptr < eofl) { switch (bufline.getChar(ptr++)) { case '\'': bufline.setState(IN_CHAR_CONST); @@ -590,7 +590,7 @@ bufline.setLookahead(--ptr); return; case '/': - if (ptr < eol) { + if (ptr < eofl) { if (bufline.getChar(ptr) == '*') { bufline.setState(IN_MULTI_COMMENT); bufline.setLookahead(--ptr); @@ -604,7 +604,7 @@ break; } // end of switch (bufline.getChar(ptr++)) - } // end of while (ptr < eol) + } // end of while (ptr < eofl) // Eol is the next token bufline.setLookahead(ptr); } @@ -626,10 +626,10 @@ private void endOfCharConst(OneLiner.BufferLine bufline, char terminator) throws BuildException { int ptr = bufline.getNext(); - int eol = bufline.length(); + int eofl = bufline.length(); char c; ptr++; // skip past initial quote - while (ptr < eol) { + while (ptr < eofl) { if ((c = bufline.getChar(ptr++)) == '\\') { ptr++; } else { @@ -638,7 +638,7 @@ return; } } - } // end of while (ptr < eol) + } // end of while (ptr < eofl) // Must have fallen through to the end of the line throw new BuildException("endOfCharConst: unterminated char constant"); } 1.124 +4 -4 ant/src/main/org/apache/tools/ant/taskdefs/Javac.java Index: Javac.java =================================================================== RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/Javac.java,v retrieving revision 1.123 retrieving revision 1.124 diff -u -r1.123 -r1.124 --- Javac.java 28 Oct 2004 07:58:56 -0000 1.123 +++ Javac.java 12 Nov 2004 15:14:59 -0000 1.124 @@ -80,7 +80,7 @@ private boolean deprecation = false; private boolean depend = false; private boolean verbose = false; - private String target; + private String targetAttribute; private Path bootclasspath; private Path extdirs; private boolean includeAntRuntime = true; @@ -565,7 +565,7 @@ * @param target the target VM */ public void setTarget(String target) { - this.target = target; + this.targetAttribute = target; } /** @@ -573,7 +573,7 @@ * @return the target VM */ public String getTarget() { - return target; + return targetAttribute; } /** 1.130 +2 -15 ant/src/main/org/apache/tools/ant/taskdefs/Javadoc.java Index: Javadoc.java =================================================================== RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/Javadoc.java,v retrieving revision 1.129 retrieving revision 1.130 diff -u -r1.129 -r1.130 --- Javadoc.java 9 Mar 2004 16:48:05 -0000 1.129 +++ Javadoc.java 12 Nov 2004 15:14:59 -0000 1.130 @@ -1257,8 +1257,6 @@ public class TagArgument extends FileSet { /** Name of the tag. */ private String name = null; - /** Description of the tag to place in the JavaDocs. */ - private String description = null; /** Whether or not the tag is enabled. */ private boolean enabled = true; /** @@ -1283,17 +1281,6 @@ } /** - * Sets the description of the tag. This is what appears in - * the JavaDoc. - * - * @param description The description of the tag. - * Must not be <code>null</code> or empty. - */ - public void setDescription (String description) { - this.description = description; - } - - /** * Sets the scope of the tag. This is in comma-separated * form, with each element being one of "all" (the default), * "overview", "packages", "types", "constructors", "methods", @@ -1389,9 +1376,9 @@ if (name == null || name.equals("")) { throw new BuildException ("No name specified for custom tag."); } - if (description != null) { + if (getDescription() != null) { return name + ":" + (enabled ? "" : "X") - + scope + ":" + description; + + scope + ":" + getDescription(); } else { return name; } 1.29 +2 -2 ant/src/main/org/apache/tools/ant/taskdefs/MacroInstance.java Index: MacroInstance.java =================================================================== RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/MacroInstance.java,v retrieving revision 1.28 retrieving revision 1.29 diff -u -r1.28 -r1.29 --- MacroInstance.java 17 Aug 2004 18:13:50 -0000 1.28 +++ MacroInstance.java 12 Nov 2004 15:14:59 -0000 1.29 @@ -257,8 +257,8 @@ RuntimeConfigurable rc = new RuntimeConfigurable( ret, ue.getTaskName()); rc.setPolyType(ue.getWrapper().getPolyType()); - Map map = ue.getWrapper().getAttributeMap(); - for (Iterator i = map.entrySet().iterator(); i.hasNext();) { + Map m = ue.getWrapper().getAttributeMap(); + for (Iterator i = m.entrySet().iterator(); i.hasNext();) { Map.Entry entry = (Map.Entry) i.next(); rc.setAttribute( (String) entry.getKey(), 1.73 +12 -11 ant/src/main/org/apache/tools/ant/taskdefs/Property.java Index: Property.java =================================================================== RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/Property.java,v retrieving revision 1.72 retrieving revision 1.73 diff -u -r1.72 -r1.73 --- Property.java 9 Mar 2004 16:48:06 -0000 1.72 +++ Property.java 12 Nov 2004 15:14:59 -0000 1.73 @@ -495,16 +495,16 @@ resolveAllProperties(props); Enumeration e = props.keys(); while (e.hasMoreElements()) { - String name = (String) e.nextElement(); - String value = props.getProperty(name); + String propertyName = (String) e.nextElement(); + String propertyValue = props.getProperty(propertyName); - String v = getProject().replaceProperties(value); + String v = getProject().replaceProperties(propertyValue); if (prefix != null) { - name = prefix + name; + propertyName = prefix + propertyName; } - addProperty(name, v); + addProperty(propertyName, v); } } @@ -531,9 +531,9 @@ */ private void resolveAllProperties(Properties props) throws BuildException { for (Enumeration e = props.keys(); e.hasMoreElements();) { - String name = (String) e.nextElement(); + String propertyName = (String) e.nextElement(); Stack referencesSeen = new Stack(); - resolve(props, name, referencesSeen); + resolve(props, propertyName, referencesSeen); } } @@ -554,10 +554,11 @@ + "defined."); } - String value = props.getProperty(name); + String propertyValue = props.getProperty(name); Vector fragments = new Vector(); Vector propertyRefs = new Vector(); - ProjectHelper.parsePropertyString(value, fragments, propertyRefs); + ProjectHelper.parsePropertyString(propertyValue, fragments, + propertyRefs); if (propertyRefs.size() != 0) { referencesSeen.push(name); @@ -580,8 +581,8 @@ } sb.append(fragment); } - value = sb.toString(); - props.put(name, value); + propertyValue = sb.toString(); + props.put(name, propertyValue); referencesSeen.pop(); } } 1.54 +7 -7 ant/src/main/org/apache/tools/ant/taskdefs/Replace.java Index: Replace.java =================================================================== RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/Replace.java,v retrieving revision 1.53 retrieving revision 1.54 diff -u -r1.53 -r1.54 --- Replace.java 21 Sep 2004 11:37:05 -0000 1.53 +++ Replace.java 12 Nov 2004 15:14:59 -0000 1.54 @@ -233,10 +233,10 @@ Properties props = getProperties(replaceFilterFile); Enumeration e = props.keys(); while (e.hasMoreElements()) { - String token = e.nextElement().toString(); + String tok = e.nextElement().toString(); Replacefilter replaceFilter = createReplacefilter(); - replaceFilter.setToken(token); - replaceFilter.setValue(props.getProperty(token)); + replaceFilter.setToken(tok); + replaceFilter.setValue(props.getProperty(tok)); } } @@ -326,12 +326,12 @@ * @throws BuildException if the file could not be found or read */ public Properties getProperties(File propertyFile) throws BuildException { - Properties properties = new Properties(); + Properties props = new Properties(); FileInputStream in = null; try { in = new FileInputStream(propertyFile); - properties.load(in); + props.load(in); } catch (FileNotFoundException e) { String message = "Property file (" + propertyFile.getPath() + ") not found."; @@ -350,7 +350,7 @@ } } - return properties; + return props; } /** @@ -382,7 +382,7 @@ BufferedReader br = new BufferedReader(reader); BufferedWriter bw = new BufferedWriter(writer); - String buf = fileUtils.readFully(br); + String buf = FileUtils.readFully(br); if (buf == null) { buf = ""; } 1.18 +20 -20 ant/src/main/org/apache/tools/ant/taskdefs/SubAnt.java Index: SubAnt.java =================================================================== RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/SubAnt.java,v retrieving revision 1.17 retrieving revision 1.18 diff -u -r1.17 -r1.18 --- SubAnt.java 2 Jul 2004 07:23:54 -0000 1.17 +++ SubAnt.java 12 Nov 2004 15:14:59 -0000 1.18 @@ -62,7 +62,7 @@ private Path buildpath; private Ant ant = null; - private String target = null; + private String subTarget = null; private String antfile = "build.xml"; private File genericantfile = null; private boolean inheritAll = false; @@ -173,8 +173,8 @@ } /* //REVISIT: there must be cleaner way of doing this, if it is merited at all - if (target == null) { - target = getOwningTarget().getName(); + if (subTarget == null) { + subTarget = getOwningTarget().getName(); } */ BuildException buildException = null; @@ -267,14 +267,14 @@ if (failOnError) { throw e; } - log("Failure for target '" + target + log("Failure for target '" + subTarget + "' of: " + antfilename + "\n" + e.getMessage(), Project.MSG_WARN); } catch (Throwable e) { if (failOnError) { throw new BuildException(e); } - log("Failure for target '" + target + log("Failure for target '" + subTarget + "' of: " + antfilename + "\n" + e.toString(), Project.MSG_WARN); @@ -326,7 +326,7 @@ */ // REVISIT: Defaults to the target name that contains this task if not specified. public void setTarget(String target) { - this.target = target; + this.subTarget = target; } /** @@ -484,38 +484,38 @@ * references necessary to run the sub-build. */ private Ant createAntTask(File directory) { - Ant ant = (Ant) getProject().createTask("ant"); - ant.setOwningTarget(getOwningTarget()); - ant.setTaskName(getTaskName()); - ant.init(); - if (target != null && target.length() > 0) { - ant.setTarget(target); + Ant antTask = (Ant) getProject().createTask("ant"); + antTask.setOwningTarget(getOwningTarget()); + antTask.setTaskName(getTaskName()); + antTask.init(); + if (subTarget != null && subTarget.length() > 0) { + antTask.setTarget(subTarget); } if (output != null) { - ant.setOutput(output); + antTask.setOutput(output); } if (directory != null) { - ant.setDir(directory); + antTask.setDir(directory); } - ant.setInheritAll(inheritAll); + antTask.setInheritAll(inheritAll); for (Enumeration i = properties.elements(); i.hasMoreElements();) { - copyProperty(ant.createProperty(), (Property) i.nextElement()); + copyProperty(antTask.createProperty(), (Property) i.nextElement()); } for (Enumeration i = propertySets.elements(); i.hasMoreElements();) { - ant.addPropertyset((PropertySet) i.nextElement()); + antTask.addPropertyset((PropertySet) i.nextElement()); } - ant.setInheritRefs(inheritRefs); + antTask.setInheritRefs(inheritRefs); for (Enumeration i = references.elements(); i.hasMoreElements();) { - ant.addReference((Ant.Reference) i.nextElement()); + antTask.addReference((Ant.Reference) i.nextElement()); } - return ant; + return antTask; } /** 1.54 +6 -6 ant/src/main/org/apache/tools/ant/taskdefs/Tar.java Index: Tar.java =================================================================== RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/Tar.java,v retrieving revision 1.53 retrieving revision 1.54 diff -u -r1.53 -r1.54 --- Tar.java 14 Apr 2004 15:42:06 -0000 1.53 +++ Tar.java 12 Nov 2004 15:14:59 -0000 1.54 @@ -94,9 +94,9 @@ * @return the tar fileset to be used as the nested element. */ public TarFileSet createTarFileSet() { - TarFileSet fileset = new TarFileSet(); - filesets.addElement(fileset); - return fileset; + TarFileSet fs = new TarFileSet(); + filesets.addElement(fs); + return fs; } @@ -750,11 +750,11 @@ */ private OutputStream compress(final OutputStream ostream) throws IOException { - final String value = getValue(); - if (GZIP.equals(value)) { + final String v = getValue(); + if (GZIP.equals(v)) { return new GZIPOutputStream(ostream); } else { - if (BZIP2.equals(value)) { + if (BZIP2.equals(v)) { ostream.write('B'); ostream.write('Z'); return new CBZip2OutputStream(ostream); 1.43 +3 -3 ant/src/main/org/apache/tools/ant/taskdefs/Untar.java Index: Untar.java =================================================================== RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/Untar.java,v retrieving revision 1.42 retrieving revision 1.43 diff -u -r1.42 -r1.43 --- Untar.java 30 Oct 2004 19:44:02 -0000 1.42 +++ Untar.java 12 Nov 2004 15:14:59 -0000 1.43 @@ -164,11 +164,11 @@ private InputStream decompress(final File file, final InputStream istream) throws IOException, BuildException { - final String value = getValue(); - if (GZIP.equals(value)) { + final String v = getValue(); + if (GZIP.equals(v)) { return new GZIPInputStream(istream); } else { - if (BZIP2.equals(value)) { + if (BZIP2.equals(v)) { final char[] magic = new char[] {'B', 'Z'}; for (int i = 0; i < magic.length; i++) { if (istream.read() != magic[i]) { 1.12 +3 -3 ant/src/main/org/apache/tools/ant/taskdefs/WhichResource.java Index: WhichResource.java =================================================================== RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/WhichResource.java,v retrieving revision 1.11 retrieving revision 1.12 diff -u -r1.11 -r1.12 --- WhichResource.java 9 Mar 2004 16:48:07 -0000 1.11 +++ WhichResource.java 12 Nov 2004 15:14:59 -0000 1.12 @@ -127,7 +127,7 @@ loader = new AntClassLoader(getProject().getCoreLoader(), getProject(), classpath, false); - String location = null; + String loc = null; if (classname != null) { //convert a class name into a resource resource = classname.replace('.', '/') + ".class"; @@ -146,8 +146,8 @@ url = loader.getResource(resource); if (url != null) { //set the property - location = url.toExternalForm(); - getProject().setNewProperty(property, location); + loc = url.toExternalForm(); + getProject().setNewProperty(property, loc); } } 1.87 +14 -14 ant/src/main/org/apache/tools/ant/taskdefs/XSLTProcess.java Index: XSLTProcess.java =================================================================== RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/XSLTProcess.java,v retrieving revision 1.86 retrieving revision 1.87 diff -u -r1.86 -r1.87 --- XSLTProcess.java 24 Jun 2004 11:56:21 -0000 1.86 +++ XSLTProcess.java 12 Nov 2004 15:14:59 -0000 1.87 @@ -460,15 +460,15 @@ File stylesheet) throws BuildException { - File outFile = null; - File inFile = null; + File outF = null; + File inF = null; try { long styleSheetLastModified = stylesheet.lastModified(); - inFile = new File(baseDir, xmlFile); + inF = new File(baseDir, xmlFile); - if (inFile.isDirectory()) { - log("Skipping " + inFile + " it is a directory.", + if (inF.isDirectory()) { + log("Skipping " + inF + " it is a directory.", Project.MSG_VERBOSE); return; } @@ -491,23 +491,23 @@ return; } - outFile = new File(destDir, outFileName[0]); + outF = new File(destDir, outFileName[0]); if (force - || inFile.lastModified() > outFile.lastModified() - || styleSheetLastModified > outFile.lastModified()) { - ensureDirectoryFor(outFile); - log("Processing " + inFile + " to " + outFile); + || inF.lastModified() > outF.lastModified() + || styleSheetLastModified > outF.lastModified()) { + ensureDirectoryFor(outF); + log("Processing " + inF + " to " + outF); configureLiaison(stylesheet); - liaison.transform(inFile, outFile); + liaison.transform(inF, outF); } } catch (Exception ex) { // If failed to process document, must delete target document, // or it will not attempt to process it the second time log("Failed to process " + inFile, Project.MSG_INFO); - if (outFile != null) { - outFile.delete(); + if (outF != null) { + outF.delete(); } throw new BuildException(ex); 1.26 +4 -4 ant/src/main/org/apache/tools/ant/taskdefs/rmic/WLRmic.java Index: WLRmic.java =================================================================== RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/rmic/WLRmic.java,v retrieving revision 1.25 retrieving revision 1.26 diff -u -r1.25 -r1.26 --- WLRmic.java 8 Oct 2004 11:09:46 -0000 1.25 +++ WLRmic.java 12 Nov 2004 15:15:22 -0000 1.26 @@ -40,8 +40,8 @@ + "set the environment variable " + "CLASSPATH."; public static final String ERROR_WLRMIC_FAILED = "Error starting WebLogic rmic: "; - public static final String RMI_STUB_SUFFIX = "_WLStub"; - public static final String RMI_SKEL_SUFFIX = "_WLSkel"; + public static final String WL_RMI_STUB_SUFFIX = "_WLStub"; + public static final String WL_RMI_SKEL_SUFFIX = "_WLSkel"; public boolean execute() throws BuildException { getRmic().log("Using WebLogic rmic", Project.MSG_VERBOSE); @@ -82,13 +82,13 @@ * Get the suffix for the rmic stub classes */ public String getStubClassSuffix() { - return RMI_STUB_SUFFIX; + return WL_RMI_STUB_SUFFIX; } /** * Get the suffix for the rmic skeleton classes */ public String getSkelClassSuffix() { - return RMI_SKEL_SUFFIX; + return WL_RMI_SKEL_SUFFIX; } } 1.34 +3 -3 ant/src/main/org/apache/tools/ant/types/AbstractFileSet.java Index: AbstractFileSet.java =================================================================== RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/types/AbstractFileSet.java,v retrieving revision 1.33 retrieving revision 1.34 diff -u -r1.33 -r1.34 --- AbstractFileSet.java 9 Mar 2004 16:48:41 -0000 1.33 +++ AbstractFileSet.java 12 Nov 2004 15:15:22 -0000 1.34 @@ -304,9 +304,9 @@ */ protected String getDataTypeName() { // look up the types in project and see if they match this class - Project project = getProject(); - if (project != null) { - Hashtable typedefs = project.getDataTypeDefinitions(); + Project p = getProject(); + if (p != null) { + Hashtable typedefs = p.getDataTypeDefinitions(); for (Enumeration e = typedefs.keys(); e.hasMoreElements();) { String typeName = (String) e.nextElement(); Class typeClass = (Class) typedefs.get(typeName); 1.59 +4 -3 ant/src/main/org/apache/tools/ant/types/CommandlineJava.java Index: CommandlineJava.java =================================================================== RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/types/CommandlineJava.java,v retrieving revision 1.58 retrieving revision 1.59 diff -u -r1.58 -r1.59 --- CommandlineJava.java 28 Oct 2004 09:12:02 -0000 1.58 +++ CommandlineJava.java 12 Nov 2004 15:15:22 -0000 1.59 @@ -106,10 +106,11 @@ listIt.add("-D" + props[i]); } } - Properties propertySets = mergePropertySets(); - for (Enumeration e = propertySets.keys(); e.hasMoreElements();) { + Properties propertySetProperties = mergePropertySets(); + for (Enumeration e = propertySetProperties.keys(); + e.hasMoreElements();) { String key = (String) e.nextElement(); - String value = propertySets.getProperty(key); + String value = propertySetProperties.getProperty(key); listIt.add("-D" + key + "=" + value); } } 1.16 +3 -3 ant/src/main/org/apache/tools/ant/types/EnumeratedAttribute.java Index: EnumeratedAttribute.java =================================================================== RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/types/EnumeratedAttribute.java,v retrieving revision 1.15 retrieving revision 1.16 diff -u -r1.15 -r1.16 --- EnumeratedAttribute.java 9 Mar 2004 16:48:41 -0000 1.15 +++ EnumeratedAttribute.java 12 Nov 2004 15:15:22 -0000 1.16 @@ -56,11 +56,11 @@ * Invoked by [EMAIL PROTECTED] org.apache.tools.ant.IntrospectionHelper IntrospectionHelper}. */ public final void setValue(String value) throws BuildException { - int index = indexOfValue(value); - if (index == -1) { + int idx = indexOfValue(value); + if (idx == -1) { throw new BuildException(value + " is not a legal value for this attribute"); } - this.index = index; + this.index = idx; this.value = value; } 1.30 +2 -2 ant/src/main/org/apache/tools/ant/types/FilterSet.java Index: FilterSet.java =================================================================== RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/types/FilterSet.java,v retrieving revision 1.29 retrieving revision 1.30 diff -u -r1.29 -r1.30 --- FilterSet.java 9 Mar 2004 16:48:41 -0000 1.29 +++ FilterSet.java 12 Nov 2004 15:15:22 -0000 1.30 @@ -284,11 +284,11 @@ props.load(in); Enumeration e = props.propertyNames(); - Vector filters = getFilters(); + Vector filts = getFilters(); while (e.hasMoreElements()) { String strPropName = (String) e.nextElement(); String strValue = props.getProperty(strPropName); - filters.addElement(new Filter(strPropName, strValue)); + filts.addElement(new Filter(strPropName, strValue)); } } catch (Exception ex) { throw new BuildException("Could not read filters from file: " 1.29 +6 -6 ant/src/main/org/apache/tools/ant/types/Mapper.java Index: Mapper.java =================================================================== RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/types/Mapper.java,v retrieving revision 1.28 retrieving revision 1.29 diff -u -r1.28 -r1.29 --- Mapper.java 22 Apr 2004 20:27:21 -0000 1.28 +++ Mapper.java 12 Nov 2004 15:15:22 -0000 1.29 @@ -198,9 +198,9 @@ try { FileNameMapper m = (FileNameMapper)(getImplementationClass().newInstance()); - final Project project = getProject(); - if (project != null) { - project.setProjectReference(m); + final Project p = getProject(); + if (p != null) { + p.setProjectReference(m); } m.setFrom(from); m.setTo(to); @@ -219,16 +219,16 @@ */ protected Class getImplementationClass() throws ClassNotFoundException { - String classname = this.classname; + String cName = this.classname; if (type != null) { - classname = type.getImplementation(); + cName = type.getImplementation(); } ClassLoader loader = (classpath == null) ? getClass().getClassLoader() : getProject().createClassLoader(classpath); - return Class.forName(classname, true, loader); + return Class.forName(cName, true, loader); } /** 1.17 +26 -26 ant/src/main/org/apache/tools/ant/types/PropertySet.java Index: PropertySet.java =================================================================== RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/types/PropertySet.java,v retrieving revision 1.16 retrieving revision 1.17 diff -u -r1.16 -r1.17 --- PropertySet.java 28 Oct 2004 09:12:02 -0000 1.16 +++ PropertySet.java 12 Nov 2004 15:15:22 -0000 1.17 @@ -75,9 +75,9 @@ } public void setBuiltin(BuiltinPropertySetName b) { - String builtin = b.getValue(); + String built_in = b.getValue(); assertValid("builtin", builtin); - this.builtin = builtin; + this.builtin = built_in; } private void assertValid(String attr, String value) { @@ -99,27 +99,27 @@ } //end nested class public void appendName(String name) { - PropertyRef ref = new PropertyRef(); - ref.setName(name); - addPropertyref(ref); + PropertyRef r = new PropertyRef(); + r.setName(name); + addPropertyref(r); } public void appendRegex(String regex) { - PropertyRef ref = new PropertyRef(); - ref.setRegex(regex); - addPropertyref(ref); + PropertyRef r = new PropertyRef(); + r.setRegex(regex); + addPropertyref(r); } public void appendPrefix(String prefix) { - PropertyRef ref = new PropertyRef(); - ref.setPrefix(prefix); - addPropertyref(ref); + PropertyRef r = new PropertyRef(); + r.setPrefix(prefix); + addPropertyref(r); } public void appendBuiltin(BuiltinPropertySetName b) { - PropertyRef ref = new PropertyRef(); - ref.setBuiltin(b); - addPropertyref(ref); + PropertyRef r = new PropertyRef(); + r.setBuiltin(b); + addPropertyref(r); } /** @@ -256,35 +256,35 @@ // Add this PropertySet's property names. for (Enumeration e = ptyRefs.elements(); e.hasMoreElements();) { - PropertyRef ref = (PropertyRef) e.nextElement(); - if (ref.name != null) { - if (prj != null && prj.getProperty(ref.name) != null) { - names.add(ref.name); + PropertyRef r = (PropertyRef) e.nextElement(); + if (r.name != null) { + if (prj != null && prj.getProperty(r.name) != null) { + names.add(r.name); } - } else if (ref.prefix != null) { + } else if (r.prefix != null) { for (Enumeration p = properties.keys(); p.hasMoreElements();) { String name = (String) p.nextElement(); - if (name.startsWith(ref.prefix)) { + if (name.startsWith(r.prefix)) { names.add(name); } } - } else if (ref.regex != null) { + } else if (r.regex != null) { RegexpMatcherFactory matchMaker = new RegexpMatcherFactory(); RegexpMatcher matcher = matchMaker.newRegexpMatcher(); - matcher.setPattern(ref.regex); + matcher.setPattern(r.regex); for (Enumeration p = properties.keys(); p.hasMoreElements();) { String name = (String) p.nextElement(); if (matcher.matches(name)) { names.add(name); } } - } else if (ref.builtin != null) { + } else if (r.builtin != null) { - if (ref.builtin.equals(BuiltinPropertySetName.ALL)) { + if (r.builtin.equals(BuiltinPropertySetName.ALL)) { names.addAll(properties.keySet()); - } else if (ref.builtin.equals(BuiltinPropertySetName.SYSTEM)) { + } else if (r.builtin.equals(BuiltinPropertySetName.SYSTEM)) { names.addAll(System.getProperties().keySet()); - } else if (ref.builtin.equals(BuiltinPropertySetName + } else if (r.builtin.equals(BuiltinPropertySetName .COMMANDLINE)) { names.addAll(getProject().getUserProperties().keySet()); } else { 1.14 +5 -5 ant/src/main/org/apache/tools/ant/types/selectors/DateSelector.java Index: DateSelector.java =================================================================== RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/types/selectors/DateSelector.java,v retrieving revision 1.13 retrieving revision 1.14 diff -u -r1.13 -r1.14 --- DateSelector.java 7 Apr 2004 22:46:51 -0000 1.13 +++ DateSelector.java 12 Nov 2004 15:17:03 -0000 1.14 @@ -142,8 +142,8 @@ * * @param cmp The comparison to perform, an EnumeratedAttribute */ - public void setWhen(TimeComparisons cmp) { - this.cmp = cmp.getIndex(); + public void setWhen(TimeComparisons tcmp) { + this.cmp = tcmp.getIndex(); } /** @@ -187,9 +187,9 @@ + parameters[i].getValue()); } } else if (WHEN_KEY.equalsIgnoreCase(paramname)) { - TimeComparisons cmp = new TimeComparisons(); - cmp.setValue(parameters[i].getValue()); - setWhen(cmp); + TimeComparisons tcmp = new TimeComparisons(); + tcmp.setValue(parameters[i].getValue()); + setWhen(tcmp); } else if (PATTERN_KEY.equalsIgnoreCase(paramname)) { setPattern(parameters[i].getValue()); } else { 1.18 +3 -3 ant/src/main/org/apache/tools/ant/types/selectors/ExtendSelector.java Index: ExtendSelector.java =================================================================== RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/types/selectors/ExtendSelector.java,v retrieving revision 1.17 retrieving revision 1.18 diff -u -r1.17 -r1.18 --- ExtendSelector.java 9 Mar 2004 16:48:47 -0000 1.17 +++ ExtendSelector.java 12 Nov 2004 15:17:03 -0000 1.18 @@ -69,9 +69,9 @@ c = Class.forName(classname, true, al); } dynselector = (FileSelector) c.newInstance(); - final Project project = getProject(); - if (project != null) { - project.setProjectReference(dynselector); + final Project p = getProject(); + if (p != null) { + p.setProjectReference(dynselector); } } catch (ClassNotFoundException cnfexcept) { setError("Selector " + classname 1.12 +5 -5 ant/src/main/org/apache/tools/ant/types/selectors/SizeSelector.java Index: SizeSelector.java =================================================================== RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/types/selectors/SizeSelector.java,v retrieving revision 1.11 retrieving revision 1.12 diff -u -r1.11 -r1.12 --- SizeSelector.java 9 Mar 2004 16:48:47 -0000 1.11 +++ SizeSelector.java 12 Nov 2004 15:17:03 -0000 1.12 @@ -137,8 +137,8 @@ * * @param cmp The comparison to perform, an EnumeratedAttribute */ - public void setWhen(SizeComparisons cmp) { - this.cmp = cmp.getIndex(); + public void setWhen(SizeComparisons scmp) { + this.cmp = scmp.getIndex(); } /** @@ -165,9 +165,9 @@ units.setValue(parameters[i].getValue()); setUnits(units); } else if (WHEN_KEY.equalsIgnoreCase(paramname)) { - SizeComparisons cmp = new SizeComparisons(); - cmp.setValue(parameters[i].getValue()); - setWhen(cmp); + SizeComparisons scmp = new SizeComparisons(); + scmp.setValue(parameters[i].getValue()); + setWhen(scmp); } else { setError("Invalid parameter " + paramname); } 1.10 +3 -3 ant/src/main/org/apache/tools/ant/types/selectors/TypeSelector.java Index: TypeSelector.java =================================================================== RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/types/selectors/TypeSelector.java,v retrieving revision 1.9 retrieving revision 1.10 diff -u -r1.9 -r1.10 --- TypeSelector.java 9 Mar 2004 16:48:47 -0000 1.9 +++ TypeSelector.java 12 Nov 2004 15:17:03 -0000 1.10 @@ -71,9 +71,9 @@ for (int i = 0; i < parameters.length; i++) { String paramname = parameters[i].getName(); if (TYPE_KEY.equalsIgnoreCase(paramname)) { - FileType type = new FileType(); - type.setValue(parameters[i].getValue()); - setType(type); + FileType t = new FileType(); + t.setValue(parameters[i].getValue()); + setType(t); } else { setError("Invalid parameter " + paramname); } 1.12 +3 -3 ant/src/main/org/apache/tools/ant/types/selectors/modifiedselector/ModifiedSelector.java Index: ModifiedSelector.java =================================================================== RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/types/selectors/modifiedselector/ModifiedSelector.java,v retrieving revision 1.11 retrieving revision 1.12 diff -u -r1.11 -r1.12 --- ModifiedSelector.java 12 Nov 2004 11:07:13 -0000 1.11 +++ ModifiedSelector.java 12 Nov 2004 15:17:08 -0000 1.12 @@ -359,12 +359,12 @@ // // ----- Set default values ----- // - Project project = getProject(); + Project p = getProject(); String filename = "cache.properties"; File cachefile = null; - if (project != null) { + if (p != null) { // normal use inside Ant - cachefile = new File(project.getBaseDir(), filename); + cachefile = new File(p.getBaseDir(), filename); // set self as a BuildListener to delay cachefile saves getProject().addBuildListener(this); 1.20 +1 -1 ant/src/main/org/apache/tools/bzip2/CBZip2InputStream.java Index: CBZip2InputStream.java =================================================================== RCS file: /home/cvs/ant/src/main/org/apache/tools/bzip2/CBZip2InputStream.java,v retrieving revision 1.19 retrieving revision 1.20 diff -u -r1.19 -r1.20 --- CBZip2InputStream.java 12 Nov 2004 12:15:13 -0000 1.19 +++ CBZip2InputStream.java 12 Nov 2004 15:17:10 -0000 1.20 @@ -126,7 +126,7 @@ private int computedBlockCRC, computedCombinedCRC; int i2, count, chPrev, ch2; - int global_i, tPos; + int tPos; int rNToGo = 0; int rTPos = 0; int j2; 1.23 +13 -13 ant/src/main/org/apache/tools/tar/TarEntry.java Index: TarEntry.java =================================================================== RCS file: /home/cvs/ant/src/main/org/apache/tools/tar/TarEntry.java,v retrieving revision 1.22 retrieving revision 1.23 diff -u -r1.22 -r1.23 --- TarEntry.java 9 Mar 2004 16:48:55 -0000 1.22 +++ TarEntry.java 12 Nov 2004 15:17:11 -0000 1.23 @@ -205,7 +205,7 @@ this.file = file; - String name = file.getPath(); + String fileName = file.getPath(); String osname = System.getProperty("os.name").toLowerCase(Locale.US); if (osname != null) { @@ -214,35 +214,35 @@ // REVIEW Would a better check be "(File.separator == '\')"? if (osname.startsWith("windows")) { - if (name.length() > 2) { - char ch1 = name.charAt(0); - char ch2 = name.charAt(1); + if (fileName.length() > 2) { + char ch1 = fileName.charAt(0); + char ch2 = fileName.charAt(1); if (ch2 == ':' && ((ch1 >= 'a' && ch1 <= 'z') || (ch1 >= 'A' && ch1 <= 'Z'))) { - name = name.substring(2); + fileName = fileName.substring(2); } } } else if (osname.indexOf("netware") > -1) { - int colon = name.indexOf(':'); + int colon = fileName.indexOf(':'); if (colon != -1) { - name = name.substring(colon + 1); + fileName = fileName.substring(colon + 1); } } } - name = name.replace(File.separatorChar, '/'); + fileName = fileName.replace(File.separatorChar, '/'); // No absolute pathnames // Windows (and Posix?) paths can start with "\\NetworkDrive\", // so we loop on starting /'s. - while (name.startsWith("/")) { - name = name.substring(1); + while (fileName.startsWith("/")) { + fileName = fileName.substring(1); } this.linkName = new StringBuffer(""); - this.name = new StringBuffer(name); + this.name = new StringBuffer(fileName); if (file.isDirectory()) { this.mode = DEFAULT_DIR_MODE; @@ -600,9 +600,9 @@ outbuf[offset++] = 0; } - long checkSum = TarUtils.computeCheckSum(outbuf); + long chk = TarUtils.computeCheckSum(outbuf); - TarUtils.getCheckSumOctalBytes(checkSum, outbuf, csOffset, CHKSUMLEN); + TarUtils.getCheckSumOctalBytes(chk, outbuf, csOffset, CHKSUMLEN); } /** 1.17 +3 -3 ant/src/main/org/apache/tools/tar/TarInputStream.java Index: TarInputStream.java =================================================================== RCS file: /home/cvs/ant/src/main/org/apache/tools/tar/TarInputStream.java,v retrieving revision 1.16 retrieving revision 1.17 diff -u -r1.16 -r1.17 --- TarInputStream.java 9 Mar 2004 16:48:55 -0000 1.16 +++ TarInputStream.java 12 Nov 2004 15:17:11 -0000 1.17 @@ -230,10 +230,10 @@ if (this.currEntry != null && this.currEntry.isGNULongNameEntry()) { // read in the name StringBuffer longName = new StringBuffer(); - byte[] buffer = new byte[256]; + byte[] buf = new byte[256]; int length = 0; - while ((length = read(buffer)) >= 0) { - longName.append(new String(buffer, 0, length)); + while ((length = read(buf)) >= 0) { + longName.append(new String(buf, 0, length)); } getNextEntry(); 1.29 +7 -7 ant/src/main/org/apache/tools/zip/ZipOutputStream.java Index: ZipOutputStream.java =================================================================== RCS file: /home/cvs/ant/src/main/org/apache/tools/zip/ZipOutputStream.java,v retrieving revision 1.28 retrieving revision 1.29 diff -u -r1.28 -r1.29 --- ZipOutputStream.java 12 Nov 2004 12:15:13 -0000 1.28 +++ ZipOutputStream.java 12 Nov 2004 15:17:12 -0000 1.29 @@ -473,9 +473,9 @@ * @since 1.14 */ public void write(int b) throws IOException { - byte[] buf = new byte[1]; - buf[0] = (byte) (b & 0xff); - write(buf, 0, 1); + byte[] buff = new byte[1]; + buff[0] = (byte) (b & 0xff); + write(buff, 0, 1); } /** @@ -694,8 +694,8 @@ if (comm == null) { comm = ""; } - byte[] comment = getBytes(comm); - writeOut((new ZipShort(comment.length)).getBytes()); + byte[] commentB = getBytes(comm); + writeOut((new ZipShort(commentB.length)).getBytes()); written += 2; // disk number start @@ -723,8 +723,8 @@ written += extra.length; // file comment - writeOut(comment); - written += comment.length; + writeOut(commentB); + written += commentB.length; } /**
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]