From 42899341187365405d0480e906844a75296acd42 Mon Sep 17 00:00:00 2001
Date: Tue, 7 Jul 2026 11:40:35 +0800
Subject: [PATCH] AutoSharedArchivePath: use effective app classpath for dump
JVM
.../os_cpu/linux_aarch64/javaThread_linux_aarch64.cpp | 10 +---------
1 file changed, 1 insertion(+), 9 deletions(-)
@@ -111,14 +111,6 @@ static char* get_java_executable_path() {
return os::strdup("java");
}
-static char* get_complete_classpath() {
- const char* env_cp = Arguments::get_property("env.class.path");
- if (env_cp == nullptr || env_cp[0] == '\0') {
- env_cp = ::getenv("CLASSPATH");
- }
- return (char *)env_cp;
-}
-
static bool can_read_classlist(const char* class_list_path) {
int fd = open(class_list_path, O_RDWR | O_CREAT, 0644);
if (fd < 0) return false;
@@ -139,7 +131,7 @@ static void create_jsa(const char* class_list_path, const char* appcds_path, con
// child process running on background
setsid();
signal(SIGHUP, SIG_IGN);
- const char* classpath = get_complete_classpath();
+ const char* classpath = Arguments::get_appclasspath();
if (classpath == nullptr) {
classpath = ".";
}
--
2.33.0