all: blidly swap out glog to our log15, logs need rework
This commit is contained in:
@ -30,8 +30,7 @@ import (
|
||||
"github.com/ethereum/go-ethereum/eth/downloader"
|
||||
"github.com/ethereum/go-ethereum/ethdb"
|
||||
"github.com/ethereum/go-ethereum/event"
|
||||
"github.com/ethereum/go-ethereum/logger"
|
||||
"github.com/ethereum/go-ethereum/logger/glog"
|
||||
"github.com/ethereum/go-ethereum/log"
|
||||
"github.com/ethereum/go-ethereum/params"
|
||||
"github.com/ethereum/go-ethereum/pow"
|
||||
)
|
||||
@ -87,7 +86,7 @@ out:
|
||||
if self.Mining() {
|
||||
self.Stop()
|
||||
atomic.StoreInt32(&self.shouldStart, 1)
|
||||
glog.V(logger.Info).Infoln("Mining operation aborted due to sync operation")
|
||||
log.Info(fmt.Sprint("Mining operation aborted due to sync operation"))
|
||||
}
|
||||
case downloader.DoneEvent, downloader.FailedEvent:
|
||||
shouldStart := atomic.LoadInt32(&self.shouldStart) == 1
|
||||
@ -124,7 +123,7 @@ func (self *Miner) Start(coinbase common.Address, threads int) {
|
||||
self.threads = threads
|
||||
|
||||
if atomic.LoadInt32(&self.canStart) == 0 {
|
||||
glog.V(logger.Info).Infoln("Can not start mining operation due to network sync (starts when finished)")
|
||||
log.Info(fmt.Sprint("Can not start mining operation due to network sync (starts when finished)"))
|
||||
return
|
||||
}
|
||||
atomic.StoreInt32(&self.mining, 1)
|
||||
@ -133,7 +132,7 @@ func (self *Miner) Start(coinbase common.Address, threads int) {
|
||||
self.worker.register(NewCpuAgent(i, self.pow))
|
||||
}
|
||||
|
||||
glog.V(logger.Info).Infof("Starting mining operation (CPU=%d TOT=%d)\n", threads, len(self.worker.agents))
|
||||
log.Info(fmt.Sprintf("Starting mining operation (CPU=%d TOT=%d)\n", threads, len(self.worker.agents)))
|
||||
self.worker.start()
|
||||
self.worker.commitNewWork()
|
||||
}
|
||||
|
Reference in New Issue
Block a user