summaryrefslogtreecommitdiff
path: root/libjava/defineclass.cc
diff options
context:
space:
mode:
authortromey <tromey@138bc75d-0d04-0410-961f-82ee72b054a4>2005-01-10 19:39:26 +0000
committertromey <tromey@138bc75d-0d04-0410-961f-82ee72b054a4>2005-01-10 19:39:26 +0000
commit743d66d0d409fc453f1172d70bdbb5bf5bfc4737 (patch)
tree966d2f436ef2b2ebadf80447ac97eca99afd09f7 /libjava/defineclass.cc
parent4c7c159ad4a0f7ba527305497199ceb813f1a3b8 (diff)
downloadgcc-743d66d0d409fc453f1172d70bdbb5bf5bfc4737.tar.gz
PR libgcj/12016, PR libgcj/18405, PR libgcj/17738:
* java/lang/Package.java (getPackages): Use VMClassLoader when appropriate. (getPackage): Likewise. * prims.cc (_Jv_CreateJavaVM): Call _Jv_RegisterBootstrapPackages. * include/jvm.h (_Jv_RegisterBootstrapPackages): Declare. * java/lang/VMClassLoader.java (getPackage): Rewrote. (getPackages): Likewise. (definedPackages): New field. (definePackageForNative): New method. * java/lang/Class.h (_Jv_FindClassInCache): Updated. * java/lang/natVMClassLoader.cc (loadClass): Updated. * defineclass.cc (handleClassBegin): Use ClassLoader.findLoadedClass. * java/lang/natClassLoader.cc (_Jv_RegisterInitiatingLoader): Rewrote. (struct _Jv_LoaderInfo): Removed. (initiated_classes): Likewise. (_Jv_UnregisterClass): Don't use initiated_classes. (_Jv_FindClassInCache): Likewise. Removed 'loader' argument. (_Jv_FindClass): Register classes found during boostrap. (BOOTSTRAP_CLASS_LIST_SIZE): New define. (bootstrap_class_list): New global. (bootstrap_index): Likewise. (_Jv_RegisterBootstrapPackages): New function. * gnu/gcj/runtime/natVMClassLoader.cc (findClass): Call definePackageForNative. (findClass): Updated. * gnu/gcj/runtime/VMClassLoader.java (definePackageForNative): New method. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@93155 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libjava/defineclass.cc')
-rw-r--r--libjava/defineclass.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/libjava/defineclass.cc b/libjava/defineclass.cc
index 1a0c4e4da60..a40bff1758e 100644
--- a/libjava/defineclass.cc
+++ b/libjava/defineclass.cc
@@ -1,6 +1,6 @@
// defineclass.cc - defining a class from .class format.
-/* Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004 Free Software Foundation
+/* Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation
This file is part of libgcj.
@@ -868,7 +868,7 @@ _Jv_ClassReader::handleClassBegin (int access_flags, int this_class, int super_c
// was ClassLoader.defineClass called with an expected class name?
if (def->name == 0)
{
- jclass orig = _Jv_FindClassInCache (loadedName, def->loader);
+ jclass orig = def->loader->findLoadedClass(loadedName->toString());
if (orig == 0)
{