+2001-05-31 Tom Tromey <tromey@redhat.com>
+
+ * java/sql/DriverManager.java (getDrivers): Handle case where
+ driver's class loader is null. From Corey Minyard.
+
2001-05-29 Tom Tromey <tromey@redhat.com>
* include/jvm.h (_Jv_ThrowNoMemory): Mark as noreturn.
/* DriverManager.java -- Manage JDBC drivers
- Copyright (C) 1999, 2000 Free Software Foundation, Inc.
+ Copyright (C) 1999, 2000, 2001 Free Software Foundation, Inc.
This file is part of GNU Classpath.
while(e.hasMoreElements())
{
Object obj = e.nextElement();
- if (!obj.getClass().getClassLoader().equals(cl))
- continue;
+
+ ClassLoader loader = obj.getClass().getClassLoader();
+
+ if (loader == null)
+ loader = ClassLoader.getSystemClassLoader();
+ if (!loader.equals(cl))
+ continue;
v.addElement(obj);
}