Merge remote-tracking branch 'origin/work-notify' into beta

This commit is contained in:
arkpar
2016-07-01 13:10:22 +02:00
7 changed files with 13 additions and 3 deletions

View File

@@ -266,7 +266,7 @@ impl Miner {
let is_new = original_work_hash.map_or(true, |h| block.block().fields().header.hash() != h);
sealing_work.push(block);
// If push notifications are enabled we assume all work items are used.
if self.work_poster.is_some() {
if self.work_poster.is_some() && is_new {
sealing_work.use_last_ref();
}
(Some((pow_hash, difficulty, number)), is_new)