OSDN Git Service

2004-05-04 Mark Wielaard <mark@klomp.org>
authormkoch <mkoch@138bc75d-0d04-0410-961f-82ee72b054a4>
Tue, 4 May 2004 05:32:46 +0000 (05:32 +0000)
committermkoch <mkoch@138bc75d-0d04-0410-961f-82ee72b054a4>
Tue, 4 May 2004 05:32:46 +0000 (05:32 +0000)
* gnu/java/nio/channels/FileChannelImpl.java
(finalize): New method.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@81469 138bc75d-0d04-0410-961f-82ee72b054a4

libjava/ChangeLog
libjava/gnu/java/nio/channels/FileChannelImpl.java

index 0a11416..9f33b3e 100644 (file)
@@ -1,3 +1,8 @@
+2004-05-04  Mark Wielaard  <mark@klomp.org>
+
+       * gnu/java/nio/channels/FileChannelImpl.java
+       (finalize): New method.
+
 2004-05-03  Andreas Tobler  <a.tobler@schweiz.ch>
 
        * Makefile.am (WARNINGS): Replace -W with the more speaking -Wextra.
index ea6ef0e..f4686b2 100644 (file)
@@ -115,6 +115,11 @@ public final class FileChannelImpl extends FileChannel
     this.mode = mode;
   }
 
+  protected void finalize() throws Throwable
+  {
+    close();
+  }
+
   public static FileChannelImpl in;
   public static FileChannelImpl out;
   public static FileChannelImpl err;