Merge "Don't look for libnpt.so in java.library.path." am: bdf22a2da2
am: b791271b74
Change-Id: I3e13058063f154880183a6aa30535e08e3e1b26c
diff --git a/src/share/back/debugInit.c b/src/share/back/debugInit.c
index 66d5282..2a1bd21 100644
--- a/src/share/back/debugInit.c
+++ b/src/share/back/debugInit.c
@@ -259,7 +259,6 @@
jint jvmtiCompileTimeMajorVersion;
jint jvmtiCompileTimeMinorVersion;
jint jvmtiCompileTimeMicroVersion;
- char *boot_path = NULL;
char npt_lib[MAXPATHLEN];
/* See if it's already loaded */
@@ -337,15 +336,10 @@
forceExit(1); /* Kill entire process, no core dump wanted */
}
- // ANDROID-CHANGED: Android uses java.library.path to store all library path information.
- JVMTI_FUNC_PTR(gdata->jvmti, GetSystemProperty)
- (gdata->jvmti, (const char *)"java.library.path",
- &boot_path);
-
- dbgsysBuildLibName(npt_lib, sizeof(npt_lib), boot_path, NPT_LIBNAME);
+ // ANDROID-CHANGED: Load libnpt.so with no path to use the system linker config to find it.
+ dbgsysBuildLibName(npt_lib, sizeof(npt_lib), "", NPT_LIBNAME);
/* Npt and Utf function init */
NPT_INITIALIZE(npt_lib, &(gdata->npt), NPT_VERSION, NULL);
- jvmtiDeallocate(boot_path);
if (gdata->npt == NULL) {
ERROR_MESSAGE(("JDWP: unable to initialize NPT library"));
return JNI_ERR;