fix(cli): defer PID file cleanup to process exit event for graceful shutdowns

This commit is contained in:
yiling
2026-06-20 13:05:50 +08:00
parent ca0c2ece75
commit b5ff76960f
-1
View File
@@ -256,7 +256,6 @@ export async function handleDaemonCommands(
process.on('exit', cleanPidFile)
const handleSignal = (signal: string) => {
cleanPidFile()
if (process.listenerCount(signal) === 1) {
process.exit(0)
}