Browse Source

Reset best shares on accepted remote block submit as well.

master
Con Kolivas 8 years ago
parent
commit
063170f4c9
  1. 8
      src/stratifier.c

8
src/stratifier.c

@ -7019,9 +7019,11 @@ static void parse_remote_block(ckpool_t *ckp, sdata_t *sdata, json_t *val, const
sha256(swap, 80, hash1); sha256(swap, 80, hash1);
sha256(hash1, 32, hash); sha256(hash1, 32, hash);
gbt_block = process_block(wb, coinbase, cblen, swap, hash, flip32, blockhash); gbt_block = process_block(wb, coinbase, cblen, swap, hash, flip32, blockhash);
/* Ignore the return value of local_block_submit here as we rely /* We rely on the remote server to give us the ID_BLOCK
* on the remote server to give us the ID_BLOCK responses */ * responses, so only use this response to determine if we
local_block_submit(ckp, gbt_block, flip32, wb->height); * should reset the best shares. */
if (local_block_submit(ckp, gbt_block, flip32, wb->height))
reset_bestshares(sdata);
put_remote_workbase(sdata, wb); put_remote_workbase(sdata, wb);
} }

Loading…
Cancel
Save