Browse Source

mempool: fix memory loading error on 32-bit machines (#3969)

* Correct memory alignment for 32-bit machine. 

Switching the `txsBytes` and `rechecking` fields of `CListMempool` to ensure the correct memory alignment for `atomic.LoadInt64` on 32-bit machine.

* Update CHANGELOG_PENDING.md for #3968

Fixed #3968 `mempool` Memory Loading Error on 32-bit Ubuntu 16.04 Machine.

* Update CHANGELOG_PENDING.md

Co-Authored-By: Anton Kaliaev <anton.kalyaev@gmail.com>
pull/3980/head
Jon 5 years ago
committed by Anton Kaliaev
parent
commit
2edd89b450
2 changed files with 2 additions and 1 deletions
  1. +1
    -0
      CHANGELOG_PENDING.md
  2. +1
    -1
      mempool/clist_mempool.go

+ 1
- 0
CHANGELOG_PENDING.md View File

@ -24,3 +24,4 @@ program](https://hackerone.com/tendermint).
### BUG FIXES:
- [consensus] \#3908 Wait `timeout_commit` to pass even if `create_empty_blocks` is `false`
- [mempool] \#3968 Fix memory loading error on 32-bit machines (@jon-certik)

+ 1
- 1
mempool/clist_mempool.go View File

@ -53,8 +53,8 @@ type CListMempool struct {
// Atomic integers
height int64 // the last block Update()'d to
rechecking int32 // for re-checking filtered txs on Update()
txsBytes int64 // total size of mempool, in bytes
rechecking int32 // for re-checking filtered txs on Update()
// Keep a cache of already-seen txs.
// This reduces the pressure on the proxyApp.


Loading…
Cancel
Save