Index: ./src/main/org/apache/tools/ant/taskdefs/optional/junit/AggregateTransformer.java
===================================================================
RCS file: /home/cvspublic/jakarta-ant/src/main/org/apache/tools/ant/taskdefs/optional/junit/AggregateTransformer.java,v
retrieving revision 1.2
diff -u -r1.2 AggregateTransformer.java
--- ./src/main/org/apache/tools/ant/taskdefs/optional/junit/AggregateTransformer.java	2001/02/13 12:32:00	1.2
+++ ./src/main/org/apache/tools/ant/taskdefs/optional/junit/AggregateTransformer.java	2001/02/28 10:39:27
@@ -281,19 +281,25 @@
     }
 
     protected void createCascadingStyleSheet() throws IOException, SAXException {
+        InputStream in = null;
         if (styleDir == null) {
-            InputStream in = getResourceAsStream("html/stylesheet.css");
-            OutputStream out = new FileOutputStream( new File(toDir, "stylesheet.css"));
-            copy(in, out);              
+            in = getResourceAsStream("html/stylesheet.css");
+        } else {
+            in = new FileInputStream(new File(styleDir, "stylesheet.css"));
         }
+        OutputStream out = new FileOutputStream( new File(toDir, "stylesheet.css"));
+        copy(in, out);
     }
 
     protected void createFrameStructure() throws IOException, SAXException{
+        InputStream in = null;
         if (styleDir == null) {
-            InputStream in = getResourceAsStream("html/index.html");
-            OutputStream out = new FileOutputStream( new File(toDir, "index.html") );
-            copy(in, out);
+            in = getResourceAsStream("html/index.html");
+        } else {
+            in = new FileInputStream(new File(styleDir, "index.html"));
         }
+        OutputStream out = new FileOutputStream( new File(toDir, "index.html") );
+        copy(in, out);
     }
         
     /**

The command completed successfully.
