This is the mail archive of the java-patches@gcc.gnu.org mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Patch: FYI: ignore nio exception in VMCompiler


I'm checking this in on the trunk and the 4.0 branch.

java.nio.BufferUnderflowException does not extend IOException,
for whatever reason.  We can see one of these if a .db file
is completely empty.

Tom

Index: ChangeLog
from  Tom Tromey  <tromey@redhat.com>

	* java/lang/VMCompiler.java (static block): Also catch
	BufferUnderflowException.

Index: java/lang/VMCompiler.java
===================================================================
RCS file: /cvs/gcc/gcc/libjava/java/lang/VMCompiler.java,v
retrieving revision 1.4.2.1
diff -u -r1.4.2.1 VMCompiler.java
--- java/lang/VMCompiler.java 7 Mar 2005 19:50:00 -0000 1.4.2.1
+++ java/lang/VMCompiler.java 21 Mar 2005 20:46:21 -0000
@@ -141,6 +141,10 @@
 	      catch (java.io.IOException _)
 		{
 		}
+	      catch (java.nio.BufferUnderflowException _)
+		{
+		  // Invalid map file.
+		}
 	    }
 	}
       }


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]