[vc] print out size of m1 message (#3761)

Signed-off-by: Leo Chen <leo@harmony.one>
pull/3763/head v4.1.4
Leo Chen 4 years ago committed by GitHub
parent 556e62da13
commit 6703b7fb34
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      consensus/view_change_construct.go

@ -407,7 +407,7 @@ func (vc *viewChange) InitPayload(
if preparedMsg != nil {
if preparedBlock := fbftlog.GetBlockByHash(preparedMsg.BlockHash); preparedBlock != nil {
if err := vc.verifyBlock(preparedBlock); err == nil {
vc.getLogger().Info().Uint64("viewID", viewID).Uint64("blockNum", blockNum).Msg("[InitPayload] add my M1 (prepared) type messaage")
vc.getLogger().Info().Uint64("viewID", viewID).Uint64("blockNum", blockNum).Int("size", binary.Size(preparedBlock)).Msg("[InitPayload] add my M1 (prepared) type messaage")
msgToSign := append(preparedMsg.BlockHash[:], preparedMsg.Payload...)
for _, key := range privKeys {
// update the dictionary key if the viewID is first time received

Loading…
Cancel
Save