Browse Source

Some minor JDK 1.1 compatibility problems. MMetricsStreamHandler.java

still won't compile.


git-svn-id: https://svn.apache.org/repos/asf/ant/core/trunk@269452 13f79535-47bb-0310-9956-ffa450edef68
master
Stefan Bodewig 24 years ago
parent
commit
36f7c9bb7b
2 changed files with 3 additions and 2 deletions
  1. +1
    -1
      src/main/org/apache/tools/ant/taskdefs/optional/metamata/AbstractMetamataTask.java
  2. +2
    -1
      src/main/org/apache/tools/ant/taskdefs/optional/metamata/MMetricsStreamHandler.java

+ 1
- 1
src/main/org/apache/tools/ant/taskdefs/optional/metamata/AbstractMetamataTask.java View File

@@ -225,7 +225,7 @@ public abstract class AbstractMetamataTask extends Task{


/** return the location of the jar file used to run */ /** return the location of the jar file used to run */
protected final File getMetamataJar(File home){ protected final File getMetamataJar(File home){
return new File(home.getAbsoluteFile(), "lib/metamata.jar");
return new File(new File(home.getAbsolutePath()), "lib/metamata.jar");
} }


/** validate options set */ /** validate options set */


+ 2
- 1
src/main/org/apache/tools/ant/taskdefs/optional/metamata/MMetricsStreamHandler.java View File

@@ -406,7 +406,8 @@ class MetricsElement {
// construct name, we'll need all this to figure out what type of // construct name, we'll need all this to figure out what type of
// construct it is since we lost all semantics :( // construct it is since we lost all semantics :(
// (#indent[/]*)(#construct.*) // (#indent[/]*)(#construct.*)
String name = (String)metrics.remove(0);
String name = (String)metrics.elementAt(0);
metrics.removeElementAt(0);
int indent = 0; int indent = 0;
pos = name.lastIndexOf('/'); pos = name.lastIndexOf('/');
if (pos != -1){ if (pos != -1){


Loading…
Cancel
Save