mirror of
https://github.com/xiaozhou233/JuiceAgent.git
synced 2026-12-05 13:05:53 +08:00
Fix: init lifecycle event payloads and clean up service listeners
- fill EventPreLoad/EventLoaded struct members instead of leaving them as uninitialized garbage; post PreLoad only after the agent environment (JavaVM/JNIEnv/JVMTI) is set so listeners can query Agent state - store (EventId, Handle) pairs in IService and add unlistenAll() to remove registered listeners on shutdown, preventing dangling callbacks into destroyed services; BytecodeService and JarLoaderService now call it from onShutdown
This commit is contained in:
1 parent
20747124d1
commit
4f433bc6ee
4 files changed
+23
-8
No files matched your search
@@ -29,6 +29,7 @@ public:
|
||||
}
|
||||
|
||||
void onShutdown() override {
|
||||
unlistenAll();
|
||||
spdlog::info("[BytecodeService] Shutdown");
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user