aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDeterminant <[email protected]>2018-09-11 22:51:19 -0400
committerDeterminant <[email protected]>2018-09-11 22:51:19 -0400
commitb730a496b39d1ecef3763c07dc8f82a3f86c07fb (patch)
tree4ae2679cacbfd372e4811fd971da6aa93b4fc1c1
parentfcdf89a2c36d3dc985d47ce46235c42d74123c5e (diff)
...
-rw-r--r--src/hotstuff.cpp1
-rw-r--r--src/hotstuff_client.cpp6
2 files changed, 4 insertions, 3 deletions
diff --git a/src/hotstuff.cpp b/src/hotstuff.cpp
index 99ab80f..1912946 100644
--- a/src/hotstuff.cpp
+++ b/src/hotstuff.cpp
@@ -410,6 +410,7 @@ void HotStuffBase::do_vote(ReplicaID last_proposer, const Vote &vote) {
}
void HotStuffBase::do_decide(Finality &&fin) {
+ part_decided++;
state_machine_execute(fin);
auto it = decision_waiting.find(fin.cmd_hash);
if (it != decision_waiting.end())
diff --git a/src/hotstuff_client.cpp b/src/hotstuff_client.cpp
index b32bcb5..d8a6087 100644
--- a/src/hotstuff_client.cpp
+++ b/src/hotstuff_client.cpp
@@ -65,8 +65,8 @@ void try_send() {
{
auto cmd = new CommandDummy(cid, cnt++);
//mn.send_msg(MsgReqCmd(*cmd), *conns.at(proposer));
- for (auto &p: conns)
- mn.send_msg(MsgReqCmd(*cmd), *(p.second));
+ MsgReqCmd msg(*cmd);
+ for (auto &p: conns) mn.send_msg(msg, *(p.second));
#ifndef HOTSTUFF_ENABLE_BENCHMARK
HOTSTUFF_LOG_INFO("send new cmd %.10s",
get_hex(cmd->get_hash()).c_str());
@@ -103,7 +103,7 @@ void client_resp_cmd_handler(MsgRespCmd &&msg, MsgNetwork<opcode_t>::Conn &) {
// it->second.rid = proposer;
// return;
// }
- if (++it->second.confirmed <= nfaulty) return; // wait for f + 1 ack
+// if (++it->second.confirmed <= nfaulty) return; // wait for f + 1 ack
#ifndef HOTSTUFF_ENABLE_BENCHMARK
HOTSTUFF_LOG_INFO("got %s, wall: %.3f, cpu: %.3f",
std::string(fin).c_str(),