mirror of
https://github.com/Ark0N/Codeman.git
synced 2026-10-07 16:09:43 +02:00
fix: medium severity audit fixes — races, leaks, perf, warnings
- Clear teams/teamTasks maps in handleInit() on SSE reconnect - Fix saveNowAsync() race condition with in-flight promise guard - Add setMaxListeners() on Session, WebServer, SubagentWatcher, ImageWatcher, TmuxManager to prevent MaxListenersExceeded warnings - Debounce persistSessionState() per-session (100ms) to reduce redundant toState() serialization across 25+ call sites - Cache getLightSessionsState() with 1s TTL to avoid re-serializing all sessions on every SSE connect and /api/sessions request Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -3097,6 +3097,8 @@ class ClaudemanApp {
|
||||
this.terminalBuffers.clear();
|
||||
this.terminalBufferCache.clear();
|
||||
this.projectInsights.clear();
|
||||
this.teams.clear();
|
||||
this.teamTasks.clear();
|
||||
// Clear all idle timers to prevent stale timers from firing
|
||||
for (const timer of this.idleTimers.values()) {
|
||||
clearTimeout(timer);
|
||||
|
||||
Reference in New Issue
Block a user