updated ethash

This commit is contained in:
obscuren 2015-03-08 01:02:39 +01:00
parent 69920c735a
commit 8ea0444655
2 changed files with 2 additions and 4 deletions

4
Godeps/Godeps.json generated
View File

@ -22,8 +22,8 @@
}, },
{ {
"ImportPath": "github.com/ethereum/ethash", "ImportPath": "github.com/ethereum/ethash",
"Comment": "v17-63-gbca024b", "Comment": "v17-64-ga323708",
"Rev": "bca024b0b30d83ec6798a5d4fa8c5fc6f937009a" "Rev": "a323708b8c4d253b8567bf6c72727d1aec302225"
}, },
{ {
"ImportPath": "github.com/ethereum/serpent-go", "ImportPath": "github.com/ethereum/serpent-go",

View File

@ -11,7 +11,6 @@ import "C"
import ( import (
"bytes" "bytes"
"encoding/binary" "encoding/binary"
"fmt"
"io/ioutil" "io/ioutil"
"log" "log"
"math/big" "math/big"
@ -293,7 +292,6 @@ func (pow *Ethash) Verify(block pow.Block) bool {
} }
func (pow *Ethash) verify(hash []byte, mixDigest []byte, difficulty *big.Int, blockNum uint64, nonce uint64) bool { func (pow *Ethash) verify(hash []byte, mixDigest []byte, difficulty *big.Int, blockNum uint64, nonce uint64) bool {
fmt.Printf("%x\n%d\n%x\n%x\n", hash, nonce, mixDigest, difficulty.Bytes())
// First check: make sure header, mixDigest, nonce are correct without hitting the DAG // First check: make sure header, mixDigest, nonce are correct without hitting the DAG
// This is to prevent DOS attacks // This is to prevent DOS attacks
chash := (*C.uint8_t)(unsafe.Pointer(&hash[0])) chash := (*C.uint8_t)(unsafe.Pointer(&hash[0]))