fix: update StatApplied when fvm apply message
This commit is contained in:
parent
2be9452ced
commit
6c40d363f5
@ -3,6 +3,7 @@ package vm
|
||||
import (
|
||||
"bytes"
|
||||
"context"
|
||||
"sync/atomic"
|
||||
"time"
|
||||
|
||||
"github.com/ipfs/go-cid"
|
||||
@ -294,6 +295,7 @@ func NewFVM(ctx context.Context, opts *VMOpts) (*FVM, error) {
|
||||
|
||||
func (vm *FVM) ApplyMessage(ctx context.Context, cmsg types.ChainMsg) (*ApplyRet, error) {
|
||||
start := build.Clock.Now()
|
||||
defer atomic.AddUint64(&StatApplied, 1)
|
||||
msgBytes, err := cmsg.VMMessage().Serialize()
|
||||
if err != nil {
|
||||
return nil, xerrors.Errorf("serializing msg: %w", err)
|
||||
@ -335,6 +337,7 @@ func (vm *FVM) ApplyMessage(ctx context.Context, cmsg types.ChainMsg) (*ApplyRet
|
||||
|
||||
func (vm *FVM) ApplyImplicitMessage(ctx context.Context, cmsg *types.Message) (*ApplyRet, error) {
|
||||
start := build.Clock.Now()
|
||||
defer atomic.AddUint64(&StatApplied, 1)
|
||||
msgBytes, err := cmsg.VMMessage().Serialize()
|
||||
if err != nil {
|
||||
return nil, xerrors.Errorf("serializing msg: %w", err)
|
||||
|
Loading…
Reference in New Issue
Block a user