OSDN Git Service

2005-04-12 Aaron Luchko <aluchko@redhat.com>
authorbryce <bryce@138bc75d-0d04-0410-961f-82ee72b054a4>
Tue, 12 Apr 2005 23:22:14 +0000 (23:22 +0000)
committerbryce <bryce@138bc75d-0d04-0410-961f-82ee72b054a4>
Tue, 12 Apr 2005 23:22:14 +0000 (23:22 +0000)
PR libgcj/20958
* gnu/gcj/runtime/PersistentByteMap.java (close): Throw IOException.
* gnu/gcj/tools/gcj_dbtool/Main.java (addJar): Make 'length' an int.

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

libjava/ChangeLog
libjava/gnu/gcj/runtime/PersistentByteMap.java
libjava/gnu/gcj/tools/gcj_dbtool/Main.java

index 03aa02c..0ae3d5e 100644 (file)
@@ -1,5 +1,11 @@
 2005-04-12  Aaron Luchko  <aluchko@redhat.com>
 
+       PR libgcj/20958
+       * gnu/gcj/runtime/PersistentByteMap.java (close): Throw IOException.
+       * gnu/gcj/tools/gcj_dbtool/Main.java (addJar): Make 'length' an int.
+
+2005-04-12  Aaron Luchko  <aluchko@redhat.com>
+
        PR libgcj/20975
        * scripts/TexinfoDoclet.java: Removed.
        * Makefile.am (texinfo): Removed.
index a20f5b8..a2b91da 100644 (file)
@@ -452,7 +452,7 @@ public class PersistentByteMap
 
   // Close the map.  Once this has been done, the map can no longer be
   // used.
-  public void close()
+  public void close() throws IOException
   {
     force();
     fc.close();
index 58e9720..f16a86a 100644 (file)
@@ -375,7 +375,7 @@ public class Main
        if (classfile.getName().endsWith(".class"))
          {
            InputStream str = jar.getInputStream(classfile);
-           long length = classfile.getSize();
+           int length = (int) classfile.getSize();
            if (length == -1)
              throw new EOFException();
 
@@ -383,7 +383,7 @@ public class Main
            int pos = 0;
            while (length - pos > 0)
              {
-               int len = str.read(data, pos, (int)(length - pos));
+               int len = str.read(data, pos, length - pos);
                if (len == -1)
                  throw new EOFException("Not enough data reading from: "
                                         + classfile.getName());