src/hotspot/share/jfr/recorder/checkpoint/types/traceid/jfrTraceId.inline.hpp
branchJEP-349-branch
changeset 57988 6fa0074508ef
parent 57983 a57907813a83
child 58157 9dca61a7df19
--- a/src/hotspot/share/jfr/recorder/checkpoint/types/traceid/jfrTraceId.inline.hpp	Tue Sep 03 11:48:31 2019 +0200
+++ b/src/hotspot/share/jfr/recorder/checkpoint/types/traceid/jfrTraceId.inline.hpp	Tue Sep 03 13:15:27 2019 +0200
@@ -108,7 +108,10 @@
   return cld->is_unsafe_anonymous() ? 0 : set_used_and_get(cld);
 }
 
-inline void JfrTraceId::set_leakp(const Klass* klass, const Method* method) {
+inline void JfrTraceId::set_leakp(const Method* method) {
+  assert(method != NULL, "invariant");
+  const Klass* const klass = method->method_holder();
+  assert(klass != NULL, "invariant");
   assert(METHOD_AND_CLASS_USED_THIS_EPOCH(klass), "invariant");
   assert(METHOD_FLAG_USED_THIS_EPOCH(method), "invariant");
   SET_LEAKP(klass);