aboutsummaryrefslogtreecommitdiff
path: root/libjava
diff options
context:
space:
mode:
authorTom Tromey <tromey@cygnus.com>2000-02-10 00:17:10 +0000
committerTom Tromey <tromey@gcc.gnu.org>2000-02-10 00:17:10 +0000
commit7e3b6e312a9f2060a707ab279e236fc464d9f518 (patch)
tree8824435a02a448b3bd1c961029b40e7eef6802a0 /libjava
parentc56c8c43b98902958bc2bf00dc793f1ce23c8536 (diff)
downloadgcc-7e3b6e312a9f2060a707ab279e236fc464d9f518.zip
gcc-7e3b6e312a9f2060a707ab279e236fc464d9f518.tar.gz
gcc-7e3b6e312a9f2060a707ab279e236fc464d9f518.tar.bz2
natRuntime.cc (_load): Call add_library.
* java/lang/natRuntime.cc (_load): Call add_library. (loadLibraryInternal): Likewise. From-SVN: r31877
Diffstat (limited to 'libjava')
-rw-r--r--libjava/ChangeLog3
-rw-r--r--libjava/java/lang/natRuntime.cc4
2 files changed, 7 insertions, 0 deletions
diff --git a/libjava/ChangeLog b/libjava/ChangeLog
index 94a1543..353e629 100644
--- a/libjava/ChangeLog
+++ b/libjava/ChangeLog
@@ -1,5 +1,8 @@
2000-02-09 Tom Tromey <tromey@cygnus.com>
+ * java/lang/natRuntime.cc (_load): Call add_library.
+ (loadLibraryInternal): Likewise.
+
* gnu/gcj/convert/natIconv.cc (Input_iconv::finalize): Call
iconv_close when handle is not NULL. Thanks to Andrew Haley.
(Output_iconv::finalize): Likewise.
diff --git a/libjava/java/lang/natRuntime.cc b/libjava/java/lang/natRuntime.cc
index d391ff4..f21a81f 100644
--- a/libjava/java/lang/natRuntime.cc
+++ b/libjava/java/lang/natRuntime.cc
@@ -119,6 +119,8 @@ java::lang::Runtime::_load (jstring path, jboolean do_search)
_Jv_Throw (new UnsatisfiedLinkError (JvNewStringLatin1 (msg)));
}
+ add_library (h);
+
void *onload = lt_dlsym (h, "JNI_OnLoad");
if (onload != NULL)
{
@@ -150,6 +152,8 @@ java::lang::Runtime::loadLibraryInternal (jstring lib)
buf[total] = '\0';
// FIXME: make sure path is absolute.
lt_dlhandle h = lt_dlopenext (buf);
+ if (h != NULL)
+ add_library (h);
return h != NULL;
#else
return false;