]> gcc.gnu.org Git - gcc.git/commitdiff
FilterOutputStream.java (write(byte[])): Rewrite according to JDK 1.2 docs.
authorBryce McKinlay <bryce@albatross.co.nz>
Tue, 15 Jun 1999 20:05:57 +0000 (20:05 +0000)
committerBryce McKinlay <bryce@gcc.gnu.org>
Tue, 15 Jun 1999 20:05:57 +0000 (21:05 +0100)
        * java/io/FilterOutputStream.java (write(byte[])): Rewrite according
        to JDK 1.2 docs.
        (write(byte[],int,int)): ditto.

From-SVN: r27537

libjava/ChangeLog
libjava/java/io/FilterOutputStream.java

index 42bec98ff0edb525fcf621f57cbc9b9d72a6d7e2..b5e1ba40b0734ae128f8f08183b602ea9c2d2f3a 100644 (file)
@@ -1,3 +1,9 @@
+1999-06-15  Bryce McKinlay  <bryce@albatross.co.nz>
+
+       * java/io/FilterOutputStream.java (write(byte[])): Rewrite according
+       to JDK 1.2 docs.
+       (write(byte[],int,int)): ditto.
+
 1999-06-14  Bryce McKinlay  <bryce@albatross.co.nz>
 
        * posix-threads.cc (_Jv_CondWait): Fix currentTimeMillis() overflow.
index 45d6fd024ade6bcc0c30ac571df0672c7305c52c..cf498a2e269a18280d5fbed24f50342e72754914 100644 (file)
@@ -46,14 +46,15 @@ public class FilterOutputStream extends OutputStream
   public void write (byte[] b) throws IOException, NullPointerException
   {
     // Don't do checking here, per Java Lang Spec.
-    out.write (b);
+    write (b, 0, b.length);
   }
 
   public void write (byte[] b, int off, int len)
     throws IOException, NullPointerException, IndexOutOfBoundsException
   {
     // Don't do checking here, per Java Lang Spec.
-    out.write(b, off, len);
+    for (int i=0; i < len; i++) 
+      write (b[off + i]);
   }
 
   // The output stream.
This page took 0.064405 seconds and 5 git commands to generate.