miner: go fmt

This commit is contained in:
obscuren 2015-04-20 00:41:50 +02:00
parent 5caf1aa1a9
commit fa729a0c55

View File

@ -59,15 +59,14 @@ out:
func (a *RemoteAgent) GetWork() [3]string { func (a *RemoteAgent) GetWork() [3]string {
var res [3]string var res [3]string
// XXX Wait here until work != nil ?
if a.work != nil { if a.work != nil {
a.currentWork = a.work a.currentWork = a.work
res[0] = a.work.HashNoNonce().Hex() res[0] = a.work.HashNoNonce().Hex()
seedHash, _ := ethash.GetSeedHash(a.currentWork.NumberU64()) seedHash, _ := ethash.GetSeedHash(a.currentWork.NumberU64())
res[1] = common.Bytes2Hex(seedHash) res[1] = common.Bytes2Hex(seedHash)
n := new(big.Int) // Calculate the "target" to be returned to the external miner
n.SetInt64(1) n := big.NewInt(1)
n.Lsh(n, 255) n.Lsh(n, 255)
n.Div(n, a.work.Difficulty()) n.Div(n, a.work.Difficulty())
n.Lsh(n, 1) n.Lsh(n, 1)