From 4d380c7a2d29ace7bab0ec88ae8edff914dfa2a2 Mon Sep 17 00:00:00 2001 From: subtly Date: Sat, 8 Aug 2015 18:05:12 +0200 Subject: [PATCH] Don't use Node, as can't be copioed. --- eth/main.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/eth/main.cpp b/eth/main.cpp index 66f04f815..fc60220f2 100644 --- a/eth/main.cpp +++ b/eth/main.cpp @@ -359,7 +359,7 @@ int main(int argc, char** argv) unsigned peers = 11; unsigned peerStretch = 7; - std::map preferredNodes; + std::map> preferredNodes; bool bootstrap = false; bool disableDiscovery = false; bool pinning = false; @@ -766,7 +766,7 @@ int main(int argc, char** argv) Public publicKey(fromHex(pubk)); try { - preferredNodes[publicKey] = Node(pubk, NodeIPEndpoint(bi::address(hostIP), port, port), required); + preferredNodes[publicKey] = make_pair(NodeIPEndpoint(bi::address::from_string(hostIP), port, port), required); } catch (...) { @@ -1110,10 +1110,10 @@ int main(int argc, char** argv) #endif for (auto const& p: preferredNodes) - if (p.second.required) - web3.requirePeer(p.first, p.second.endpoint); + if (p.second.second) + web3.requirePeer(p.first, p.second.first); else - web3.addNode(p.first, p.second.endpoint); + web3.addNode(p.first, p.second.first); if (bootstrap) for (auto const& i: Host::pocHosts())