storgefsm: Use locks correctly

This commit is contained in:
Łukasz Magiera 2021-03-12 15:01:00 +01:00
parent 5c605d99e2
commit 957d3f0636

View File

@ -412,7 +412,7 @@ func (m *Sealing) onUpdateSector(ctx context.Context, state *SectorInfo) error {
// trigger more input processing when we've dipped below max sealing limits
if shouldUpdateInput {
go func() {
m.inputLk.Unlock()
m.inputLk.Lock()
defer m.inputLk.Unlock()
if err := m.updateInput(ctx, sp); err != nil {