aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDeterminant <[email protected]>2019-04-07 18:08:18 -0400
committerDeterminant <[email protected]>2019-04-07 18:08:18 -0400
commitff646424fb989cb5566c7e847280c83465237d10 (patch)
treef89d35995e96171f51d790247c5792dc8c1c08db
parent491753f5191f4ec74a4d8129797f375aa2b24ece (diff)
...
-rw-r--r--src/consensus.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/consensus.cpp b/src/consensus.cpp
index b57e258..f752515 100644
--- a/src/consensus.cpp
+++ b/src/consensus.cpp
@@ -119,9 +119,8 @@ void HotStuffCore::update(const block_t &nblk) {
const block_t &blk = *it;
blk->decision = 1;
LOG_PROTO("commit %s", std::string(*blk).c_str());
- size_t idx = 0;
- for (auto cmd: blk->cmds)
- do_decide(Finality(id, 1, idx, blk->height,
+ for (size_t i = 0; i < blks->cmds.size(); i++)
+ do_decide(Finality(id, 1, i, blk->height,
cmd, blk->get_hash()));
}
bexec = p;