* Miner tweaks (#1797) * Mining fixes. - Use queue to determine whether we're mining - Kick stale hash rates Fixes #1794 Fixes #1641 * Fix tests. * Address grumbles. * Fixed tests
This commit is contained in:
@@ -70,6 +70,9 @@ impl<T> UsingQueue<T> where T: Clone {
|
||||
self.pending = Some(b);
|
||||
}
|
||||
|
||||
/// Is there anything in the queue currently?
|
||||
pub fn is_in_use(&self) -> bool { self.in_use.len() > 0 }
|
||||
|
||||
/// Clears everything; the queue is entirely reset.
|
||||
pub fn reset(&mut self) {
|
||||
self.pending = None;
|
||||
|
||||
Reference in New Issue
Block a user