Browse Source

abci: fix socket client error for state sync responses (#5395)

This caused the node to crash whenever any state sync-related request was called via the ABCI UNIX socket client.
pull/5399/head
Erik Grinaker 4 years ago
committed by GitHub
parent
commit
ebfe0cbb8c
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 9 additions and 0 deletions
  1. +1
    -0
      CHANGELOG_PENDING.md
  2. +8
    -0
      abci/client/socket_client.go

+ 1
- 0
CHANGELOG_PENDING.md View File

@ -51,3 +51,4 @@ Friendly reminder, we have a [bug bounty program](https://hackerone.com/tendermi
- [store] \#5382 Fix race conditions when loading/saving/pruning blocks (@erikgrinaker)
- [light] [\#5307](https://github.com/tendermint/tendermint/pull/5307) Persist correct proposer priority in light client validator sets (@cmwaters)
- [docker] \#5385 Fix incorrect `time_iota_ms` default setting causing block timestamp drift (@erikgrinaker)
- [abci] \#5395 Fix socket client error for state sync responses (@erikgrinaker)

+ 8
- 0
abci/client/socket_client.go View File

@ -486,6 +486,14 @@ func resMatchesReq(req *types.Request, res *types.Response) (ok bool) {
_, ok = res.Value.(*types.Response_BeginBlock)
case *types.Request_EndBlock:
_, ok = res.Value.(*types.Response_EndBlock)
case *types.Request_ApplySnapshotChunk:
_, ok = res.Value.(*types.Response_ApplySnapshotChunk)
case *types.Request_LoadSnapshotChunk:
_, ok = res.Value.(*types.Response_LoadSnapshotChunk)
case *types.Request_ListSnapshots:
_, ok = res.Value.(*types.Response_ListSnapshots)
case *types.Request_OfferSnapshot:
_, ok = res.Value.(*types.Response_OfferSnapshot)
}
return ok
}


Loading…
Cancel
Save