From adef3e3e4b47435d9eae2575b569b54b193e2b14 Mon Sep 17 00:00:00 2001 From: Elif Aslan Date: Tue, 30 Sep 2025 16:12:17 +0000 Subject: [PATCH] backport of 8ec6b8de3bb3d7aeebdcb45d761b18cce3bab75e --- src/hotspot/share/runtime/vmOperations.cpp | 2 -- src/hotspot/share/services/threadService.cpp | 1 + 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/src/hotspot/share/runtime/vmOperations.cpp b/src/hotspot/share/runtime/vmOperations.cpp index 9b408f620fa..55cefefc1c5 100644 --- a/src/hotspot/share/runtime/vmOperations.cpp +++ b/src/hotspot/share/runtime/vmOperations.cpp @@ -229,7 +229,6 @@ VM_ThreadDump::VM_ThreadDump(ThreadDumpResult* result, _result = result; _num_threads = 0; // 0 indicates all threads _threads = NULL; - _result = result; _max_depth = max_depth; _with_locked_monitors = with_locked_monitors; _with_locked_synchronizers = with_locked_synchronizers; @@ -244,7 +243,6 @@ VM_ThreadDump::VM_ThreadDump(ThreadDumpResult* result, _result = result; _num_threads = num_threads; _threads = threads; - _result = result; _max_depth = max_depth; _with_locked_monitors = with_locked_monitors; _with_locked_synchronizers = with_locked_synchronizers; diff --git a/src/hotspot/share/services/threadService.cpp b/src/hotspot/share/services/threadService.cpp index 51db7f13747..0aa4b4434a2 100644 --- a/src/hotspot/share/services/threadService.cpp +++ b/src/hotspot/share/services/threadService.cpp @@ -673,6 +673,7 @@ void ThreadStackTrace::dump_stack_at_safepoint(int maxDepth) { if (_thread->has_last_Java_frame()) { RegisterMap reg_map(_thread); + ResourceMark rm; vframe* start_vf = _thread->last_java_vframe(®_map); int count = 0; for (vframe* f = start_vf; f; f = f->sender() ) {