Fix locking when pushing subsystem updates

This commit is contained in:
Patrick Pacher 2020-10-07 09:00:13 +02:00
parent ea02f59b14
commit 4756896d32
No known key found for this signature in database
GPG key ID: E8CD2DA160925A6D

View file

@ -207,11 +207,12 @@ func (mng *Manager) handleModuleUpdate(m *modules.Module) {
}
subsys.Lock()
defer subsys.Unlock()
updated := compareAndUpdateStatus(m, ms)
if updated {
subsys.makeSummary()
}
subsys.Unlock()
if updated {
mng.pushUpdate(subsys)