We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3153489 commit c579a3eCopy full SHA for c579a3e
staticaddr/deposit/manager.go
@@ -191,10 +191,15 @@ func (m *Manager) recoverDeposits(ctx context.Context) error {
191
}
192
193
// Send the OnRecover event to the state machine.
194
- err = fsm.SendEvent(ctx, OnRecover, nil)
195
- if err != nil {
196
- log.Errorf("Error sending OnStart event: %v", err)
197
- }
+ // TODO(hieblmi): Add a unit test that would fail with the
+ // dead-lock before the fsm was passed in.
+ go func(fsm *FSM) {
+ err := fsm.SendEvent(ctx, OnRecover, nil)
198
+ if err != nil {
199
+ log.Errorf("Error sending OnStart event: %v",
200
+ err)
201
+ }
202
+ }(fsm)
203
204
m.mu.Lock()
205
m.activeDeposits[d.OutPoint] = fsm
0 commit comments