Lock newly created task to avoid simultaneous access

This commit is contained in:
Ingo Oppermann 2025-07-15 15:32:51 +02:00
parent 5d91db915f
commit d93cfc7564
No known key found for this signature in database
GPG Key ID: 2AB32426E9DD229E

View File

@ -1236,6 +1236,9 @@ func (r *restream) updateProcess(task *task, config *app.Config) error {
return fmt.Errorf("delete process: %w", err)
}
t.Lock()
defer t.Unlock()
r.tasks.Store(tid, t)
// set filesystem cleanup rules