Browse Source

Fix for previous.

cl-refactor
Gav Wood 10 years ago
parent
commit
fff8c42240
  1. 4
      eth/main.cpp

4
eth/main.cpp

@ -707,6 +707,8 @@ int main(int argc, char** argv)
if (sessionSecret) if (sessionSecret)
sigKey = KeyPair(sessionSecret); sigKey = KeyPair(sessionSecret);
ProofOfWork::GPUMiner::setDefaultDevice(openclDevice);
// Two codepaths is necessary since named block require database, but numbered // Two codepaths is necessary since named block require database, but numbered
// blocks are superuseful to have when database is already open in another process. // blocks are superuseful to have when database is already open in another process.
if (mode == OperationMode::DAGInit && !(initDAG == LatestBlock || initDAG == PendingBlock)) if (mode == OperationMode::DAGInit && !(initDAG == LatestBlock || initDAG == PendingBlock))
@ -734,8 +736,6 @@ int main(int argc, char** argv)
if (mode == OperationMode::DAGInit) if (mode == OperationMode::DAGInit)
doInitDAG(web3.ethereum()->blockChain().number() + (initDAG == PendingBlock ? 30000 : 0)); doInitDAG(web3.ethereum()->blockChain().number() + (initDAG == PendingBlock ? 30000 : 0));
ProofOfWork::GPUMiner::setDefaultDevice(openclDevice);
auto toNumber = [&](string const& s) -> unsigned { auto toNumber = [&](string const& s) -> unsigned {
if (s == "latest") if (s == "latest")
return web3.ethereum()->number(); return web3.ethereum()->number();

Loading…
Cancel
Save