From d3e84cc8b4d995b4cec505b1b183b44d55f61453 Mon Sep 17 00:00:00 2001 From: obscuren Date: Fri, 15 May 2015 16:20:50 +0200 Subject: [PATCH] miner: properly check for mining operation on Register --- miner/miner.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/miner/miner.go b/miner/miner.go index 6c220b1a6..19d39a605 100644 --- a/miner/miner.go +++ b/miner/miner.go @@ -101,7 +101,7 @@ func (self *Miner) Stop() { } func (self *Miner) Register(agent Agent) { - if atomic.LoadInt32(&self.mining) == 0 { + if self.Mining() { agent.Start() }