debug: Check error in AdvanceBlockCmd

This commit is contained in:
Łukasz Magiera 2020-02-06 03:09:52 +01:00
parent e7a1be4dde
commit 85f91a1114

View File

@ -36,6 +36,9 @@ func init() {
} }
msgs, err := miner.SelectMessages(ctx, api.StateGetActor, head, pending) msgs, err := miner.SelectMessages(ctx, api.StateGetActor, head, pending)
if err != nil {
return err
}
if len(msgs) > build.BlockMessageLimit { if len(msgs) > build.BlockMessageLimit {
log.Error("SelectMessages returned too many messages: ", len(msgs)) log.Error("SelectMessages returned too many messages: ", len(msgs))
msgs = msgs[:build.BlockMessageLimit] msgs = msgs[:build.BlockMessageLimit]