Golang implemented sidechain for Bytom
Révision | f0a522057a65acf27966e5bbc48b5d6a7392587e (tree) |
---|---|
l'heure | 2020-10-26 15:26:25 |
Auteur | Paladz <yzhu101@uott...> |
Commiter | GitHub |
prepare 1.1.6 (#552)
Co-authored-by: paladz <colt@ColtdeMacBook-Pro.local>
@@ -264,7 +264,7 @@ func (m *Manager) handleTransactionMsg(peer *peers.Peer, msg *msgs.TransactionMe | ||
264 | 264 | } |
265 | 265 | |
266 | 266 | if m.mempool.IsDust(tx) { |
267 | - m.peers.ProcessIllegal(peer.ID(), security.LevelMsgIllegal, "receive dust tx msg") | |
267 | + log.WithFields(log.Fields{"tx_hash": tx.ID.String(), "peer": peer.Addr()}).Warn("receive dust tx msg") | |
268 | 268 | return |
269 | 269 | } |
270 | 270 |
@@ -331,10 +331,9 @@ func (c *Chain) reorganizeChain(blockHeader *types.BlockHeader) error { | ||
331 | 331 | log.WithFields(log.Fields{"module": logModule, "height": blockHeader.Height, "hash": blockHash.String()}).Debug("attach from mainchain") |
332 | 332 | } |
333 | 333 | |
334 | - if len(detachBlockHeaders) > 0 && | |
335 | - detachBlockHeaders[len(detachBlockHeaders)-1].Height <= c.lastIrrBlockHeader.Height && | |
336 | - irrBlockHeader.Height <= c.lastIrrBlockHeader.Height { | |
337 | - return errors.New("rollback block below the height of irreversible block") | |
334 | + if len(detachBlockHeaders) > 0 && detachBlockHeaders[len(detachBlockHeaders)-1].Height <= c.lastIrrBlockHeader.Height && irrBlockHeader.Height <= c.lastIrrBlockHeader.Height { | |
335 | + log.WithField("module", logModule).Warn("rollback block below the height of irreversible block") | |
336 | + return nil | |
338 | 337 | } |
339 | 338 | |
340 | 339 | consensusResults = append(consensusResults, consensusResult.Fork()) |
@@ -47,7 +47,7 @@ const ( | ||
47 | 47 | |
48 | 48 | var ( |
49 | 49 | // The full version string |
50 | - Version = "1.1.5" | |
50 | + Version = "1.1.6" | |
51 | 51 | // GitCommit is set with --ldflags "-X main.gitCommit=$(git rev-parse HEAD)" |
52 | 52 | GitCommit string |
53 | 53 | Status *UpdateStatus |