This is the mail archive of the
java-patches@sourceware.cygnus.com
mailing list for the Java project.
Patch: Fix PR libgcj/179
- To: java-patches at sourceware dot cygnus dot com
- Subject: Patch: Fix PR libgcj/179
- From: Bryce McKinlay <bryce at albatross dot co dot nz>
- Date: Sat, 18 Mar 2000 14:46:11 +1300
2000-03-18 Bryce McKinlay <bryce@albatross.co.nz>
* java/lang/natClass.cc (_Jv_IsAssignableFrom): If an interface
has
no idt, it is not implemented by any loaded class, so return
false.
Index: natClass.cc
===================================================================
RCS file: /cvs/java/libgcj/libjava/java/lang/natClass.cc,v
retrieving revision 1.20
diff -u -r1.20 natClass.cc
--- natClass.cc 2000/03/09 09:22:36 1.20
+++ natClass.cc 2000/03/18 01:41:04
@@ -920,6 +920,8 @@
_Jv_IDispatchTable *cl_idt = source->idt;
_Jv_IDispatchTable *if_idt = target->idt;
jshort cl_iindex = cl_idt->cls.iindex;
+ if (if_idt == NULL)
+ return false; // No class implementing TARGET has been loaded.
if (cl_iindex <= if_idt->iface.ioffsets[0])
{
jshort offset = if_idt->iface.ioffsets[cl_iindex];