fix incorrect deferred vm release
This commit is contained in:
parent
317a87d669
commit
f11a7f8940
@ -108,7 +108,7 @@ func SetupStorageMiners(ctx context.Context, cs *store.ChainStore, sys vm.Syscal
|
||||
if err != nil {
|
||||
return cid.Undef, fmt.Errorf("creating vm: %w", err)
|
||||
}
|
||||
defer genesisVm.Done()
|
||||
defer func() { genesisVm.Done() }()
|
||||
|
||||
if len(miners) == 0 {
|
||||
return cid.Undef, xerrors.New("no genesis miners")
|
||||
|
@ -159,7 +159,7 @@ func (sm *StateManager) callInternal(ctx context.Context, msg *types.Message, pr
|
||||
if err != nil {
|
||||
return nil, xerrors.Errorf("failed to set up vm: %w", err)
|
||||
}
|
||||
defer vmi.Done()
|
||||
defer func() { vmi.Done() }()
|
||||
|
||||
for i, m := range priorMsgs {
|
||||
_, err = vmi.ApplyMessage(ctx, m)
|
||||
|
Loading…
Reference in New Issue
Block a user