From 5058854b867323dd6537d7387bf20a9d5f258084 Mon Sep 17 00:00:00 2001 From: Matthias Baesken Date: Fri, 18 Aug 2023 06:45:18 +0000 Subject: [PATCH] 8314389: AttachListener::pd_set_flag obsolete Reviewed-by: cjplummer, mdoerr, sspitsyn --- src/hotspot/os/aix/attachListener_aix.cpp | 5 ----- src/hotspot/os/bsd/attachListener_bsd.cpp | 5 ----- src/hotspot/os/linux/attachListener_linux.cpp | 5 ----- src/hotspot/os/windows/attachListener_windows.cpp | 5 ----- src/hotspot/share/services/attachListener.cpp | 5 +---- src/hotspot/share/services/attachListener.hpp | 3 --- 6 files changed, 1 insertion(+), 27 deletions(-) diff --git a/src/hotspot/os/aix/attachListener_aix.cpp b/src/hotspot/os/aix/attachListener_aix.cpp index a02d337af46..7f5917f1357 100644 --- a/src/hotspot/os/aix/attachListener_aix.cpp +++ b/src/hotspot/os/aix/attachListener_aix.cpp @@ -579,11 +579,6 @@ void AttachListener::pd_data_dump() { os::signal_notify(SIGQUIT); } -jint AttachListener::pd_set_flag(AttachOperation* op, outputStream* out) { - out->print_cr("flag '%s' cannot be changed", op->arg(0)); - return JNI_ERR; -} - void AttachListener::pd_detachall() { // Cleanup server socket to detach clients. listener_cleanup(); diff --git a/src/hotspot/os/bsd/attachListener_bsd.cpp b/src/hotspot/os/bsd/attachListener_bsd.cpp index cf1ca453089..07a49bd497b 100644 --- a/src/hotspot/os/bsd/attachListener_bsd.cpp +++ b/src/hotspot/os/bsd/attachListener_bsd.cpp @@ -542,11 +542,6 @@ void AttachListener::pd_data_dump() { os::signal_notify(SIGQUIT); } -jint AttachListener::pd_set_flag(AttachOperation* op, outputStream* out) { - out->print_cr("flag '%s' cannot be changed", op->arg(0)); - return JNI_ERR; -} - void AttachListener::pd_detachall() { // do nothing for now } diff --git a/src/hotspot/os/linux/attachListener_linux.cpp b/src/hotspot/os/linux/attachListener_linux.cpp index 139fd58774a..359983ccb07 100644 --- a/src/hotspot/os/linux/attachListener_linux.cpp +++ b/src/hotspot/os/linux/attachListener_linux.cpp @@ -547,11 +547,6 @@ void AttachListener::pd_data_dump() { os::signal_notify(SIGQUIT); } -jint AttachListener::pd_set_flag(AttachOperation* op, outputStream* out) { - out->print_cr("flag '%s' cannot be changed", op->arg(0)); - return JNI_ERR; -} - void AttachListener::pd_detachall() { // do nothing for now } diff --git a/src/hotspot/os/windows/attachListener_windows.cpp b/src/hotspot/os/windows/attachListener_windows.cpp index d14ce2a848c..da3b6c56739 100644 --- a/src/hotspot/os/windows/attachListener_windows.cpp +++ b/src/hotspot/os/windows/attachListener_windows.cpp @@ -391,11 +391,6 @@ void AttachListener::pd_data_dump() { os::signal_notify(SIGBREAK); } -jint AttachListener::pd_set_flag(AttachOperation* op, outputStream* out) { - out->print_cr("flag '%s' cannot be changed", op->arg(0)); - return JNI_ERR; -} - void AttachListener::pd_detachall() { // do nothing for now } diff --git a/src/hotspot/share/services/attachListener.cpp b/src/hotspot/share/services/attachListener.cpp index ebbb2e10036..630ceb8e998 100644 --- a/src/hotspot/share/services/attachListener.cpp +++ b/src/hotspot/share/services/attachListener.cpp @@ -319,13 +319,10 @@ static jint set_flag(AttachOperation* op, outputStream* out) { int ret = WriteableFlags::set_flag(op->arg(0), op->arg(1), JVMFlagOrigin::ATTACH_ON_DEMAND, err_msg); if (ret != JVMFlag::SUCCESS) { if (ret == JVMFlag::NON_WRITABLE) { - // if the flag is not manageable try to change it through - // the platform dependent implementation - return AttachListener::pd_set_flag(op, out); + out->print_cr("flag '%s' cannot be changed", op->arg(0)); } else { out->print_cr("%s", err_msg.buffer()); } - return JNI_ERR; } return JNI_OK; diff --git a/src/hotspot/share/services/attachListener.hpp b/src/hotspot/share/services/attachListener.hpp index bef4087e2ea..c49f996cdb4 100644 --- a/src/hotspot/share/services/attachListener.hpp +++ b/src/hotspot/share/services/attachListener.hpp @@ -121,9 +121,6 @@ class AttachListener: AllStatic { // platform specific initialization static int pd_init(); - // platform specific flag change - static jint pd_set_flag(AttachOperation* op, outputStream* out); - // platform specific detachall static void pd_detachall();