1
0
Fork 0

fix: address review finding

This commit is contained in:
Adriaan Schmidt 2026-06-08 10:16:59 +02:00
parent 9a4895a6f5
commit be3e6f6a96

View file

@ -449,9 +449,9 @@ class KthreadPlugin(base.Plugin):
except ThreadNoLongerExists:
self._kthread_internal_remove(pid)
self._instance_count -= 1
if self._instance_count == 0:
if have_perf:
self._perf_monitor_shutdown()
need_shutdown = (self._instance_count == 0)
if need_shutdown and have_perf:
self._perf_monitor_shutdown()
#
# internal bookkeeping (self._kthreads)