Make Equihash solvers cancellable

The miner only cancels the solver when chainActive.Tip() changes.

Closes #1055
This commit is contained in:
Jack Grigg
2016-07-20 19:06:49 +12:00
parent e117ff7651
commit 2dbabb1159
7 changed files with 83 additions and 36 deletions

View File

@@ -206,7 +206,7 @@ BOOST_AUTO_TEST_CASE(CreateNewBlock_validity)
// (x_1, x_2, ...) = A(I, V, n, k)
std::set<std::vector<unsigned int>> solns;
EhOptimisedSolve(n, k, curr_state, solns);
EhOptimisedSolveUncancellable(n, k, curr_state, solns);
bool ret;
for (auto soln : solns) {