From c1bb07e65f550e043d9a387d3978e651a1b7a15d Mon Sep 17 00:00:00 2001 From: Determinant Date: Tue, 2 Jul 2019 03:00:31 -0400 Subject: enable TLS for replica-replica connections --- src/hotstuff_client.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/hotstuff_client.cpp') diff --git a/src/hotstuff_client.cpp b/src/hotstuff_client.cpp index 08f2a2e..9f7423d 100644 --- a/src/hotstuff_client.cpp +++ b/src/hotstuff_client.cpp @@ -156,13 +156,13 @@ int main(int argc, char **argv) { auto idx = opt_idx->get(); max_iter_num = opt_max_iter_num->get(); max_async_num = opt_max_async_num->get(); - std::vector> raw; + std::vector raw; for (const auto &s: opt_replicas->get()) { auto res = salticidae::trim_all(salticidae::split(s, ",")); - if (res.size() != 2) + if (res.size() < 1) throw HotStuffError("format error"); - raw.push_back(std::make_pair(res[0], res[1])); + raw.push_back(res[0]); } if (!(0 <= idx && (size_t)idx < raw.size() && raw.size() > 0)) @@ -170,7 +170,7 @@ int main(int argc, char **argv) { cid = opt_cid->get() != -1 ? opt_cid->get() : idx; for (const auto &p: raw) { - auto _p = split_ip_port_cport(p.first); + auto _p = split_ip_port_cport(p); size_t _; replicas.push_back(NetAddr(NetAddr(_p.first).ip, htons(stoi(_p.second, &_)))); } -- cgit v1.2.3