aboutsummaryrefslogtreecommitdiffstats
path: root/miner/remote_agent.go
diff options
context:
space:
mode:
authorPéter Szilágyi <peterke@gmail.com>2017-02-23 22:49:05 +0800
committerGitHub <noreply@github.com>2017-02-23 22:49:05 +0800
commit357732a8404c9fe4d02f041d20a0d05381a3e6d1 (patch)
treeedaf8a63eb7f7434cd9b9cbd764b3c4c3d76191e /miner/remote_agent.go
parent29fac7de448c85049a97cbec3dc0819122bd2cb0 (diff)
parentf89dd627760b43bd405cb3db1e5efdb100835db5 (diff)
downloadgo-tangerine-357732a8404c9fe4d02f041d20a0d05381a3e6d1.tar
go-tangerine-357732a8404c9fe4d02f041d20a0d05381a3e6d1.tar.gz
go-tangerine-357732a8404c9fe4d02f041d20a0d05381a3e6d1.tar.bz2
go-tangerine-357732a8404c9fe4d02f041d20a0d05381a3e6d1.tar.lz
go-tangerine-357732a8404c9fe4d02f041d20a0d05381a3e6d1.tar.xz
go-tangerine-357732a8404c9fe4d02f041d20a0d05381a3e6d1.tar.zst
go-tangerine-357732a8404c9fe4d02f041d20a0d05381a3e6d1.zip
Merge pull request #3696 from karalabe/contextual-logger
Contextual logger
Diffstat (limited to 'miner/remote_agent.go')
-rw-r--r--miner/remote_agent.go8
1 files changed, 4 insertions, 4 deletions
diff --git a/miner/remote_agent.go b/miner/remote_agent.go
index 23277bac8..ec9d2c199 100644
--- a/miner/remote_agent.go
+++ b/miner/remote_agent.go
@@ -18,6 +18,7 @@ package miner
import (
"errors"
+ "fmt"
"math/big"
"sync"
"sync/atomic"
@@ -26,8 +27,7 @@ import (
"github.com/ethereum/ethash"
"github.com/ethereum/go-ethereum/common"
"github.com/ethereum/go-ethereum/core/types"
- "github.com/ethereum/go-ethereum/logger"
- "github.com/ethereum/go-ethereum/logger/glog"
+ "github.com/ethereum/go-ethereum/log"
"github.com/ethereum/go-ethereum/pow"
)
@@ -140,13 +140,13 @@ func (a *RemoteAgent) SubmitWork(nonce types.BlockNonce, mixDigest, hash common.
// Make sure the work submitted is present
work := a.work[hash]
if work == nil {
- glog.V(logger.Info).Infof("Work was submitted for %x but no pending work found", hash)
+ log.Info(fmt.Sprintf("Work was submitted for %x but no pending work found", hash))
return false
}
// Make sure the PoW solutions is indeed valid
block := work.Block.WithMiningResult(nonce, mixDigest)
if !a.pow.Verify(block) {
- glog.V(logger.Warn).Infof("Invalid PoW submitted for %x", hash)
+ log.Warn(fmt.Sprintf("Invalid PoW submitted for %x", hash))
return false
}
// Solutions seems to be valid, return to the miner and notify acceptance