From eb0d8c4216b5c40364ccda01bca76acfb41ccd9d Mon Sep 17 00:00:00 2001 From: Jianping Wu Date: Tue, 26 Feb 2019 15:27:48 -0800 Subject: [PATCH] Fixed build errors. --- build/env.sh | 2 +- main.go | 4 ++-- rpc/rpc.go | 2 +- stratum/api.go | 4 ++-- stratum/blocks.go | 2 +- stratum/handlers.go | 2 +- stratum/miner.go | 6 +++--- stratum/stratum.go | 6 +++--- 8 files changed, 14 insertions(+), 14 deletions(-) diff --git a/build/env.sh b/build/env.sh index 7e7e557..cc1ef1e 100755 --- a/build/env.sh +++ b/build/env.sh @@ -14,7 +14,7 @@ ethdir="$workspace/src/github.com/kevacoin-project" if [ ! -L "$ethdir/keva-stratum" ]; then mkdir -p "$ethdir" cd "$ethdir" - ln -s ../../../../../. monero-stratum + ln -s ../../../../../. keva-stratum cd "$root" fi diff --git a/main.go b/main.go index d552f99..3628b38 100644 --- a/main.go +++ b/main.go @@ -10,8 +10,8 @@ import ( "runtime" "time" - "./pool" - "./stratum" + "github.com/kevacoin-project/keva-stratum/pool" + "github.com/kevacoin-project/keva-stratum/stratum" "github.com/goji/httpauth" "github.com/gorilla/mux" diff --git a/rpc/rpc.go b/rpc/rpc.go index 572ba10..cbdab21 100644 --- a/rpc/rpc.go +++ b/rpc/rpc.go @@ -11,7 +11,7 @@ import ( "sync/atomic" "time" - "../pool" + "github.com/kevacoin-project/keva-stratum/pool" ) type RPCClient struct { diff --git a/stratum/api.go b/stratum/api.go index ad67456..e976913 100644 --- a/stratum/api.go +++ b/stratum/api.go @@ -6,8 +6,8 @@ import ( "sync/atomic" "time" - "../rpc" - "../util" + "github.com/kevacoin-project/keva-stratum/rpc" + "github.com/kevacoin-project/keva-stratum/util" ) func (s *StratumServer) StatsIndex(w http.ResponseWriter, r *http.Request) { diff --git a/stratum/blocks.go b/stratum/blocks.go index a109ee0..bb37043 100644 --- a/stratum/blocks.go +++ b/stratum/blocks.go @@ -26,7 +26,7 @@ func (b *BlockTemplate) nextBlob(extraNonce uint32, instanceId []byte) string { copy(blobBuff[b.reservedOffset+4:b.reservedOffset+7], instanceId) copy(blobBuff[b.reservedOffset:], extraBuff.Bytes()) //blob := cnutil.ConvertBlob(blobBuff) - blob := nil //TODO: fix this! + blob := []byte("fix this!") //TODO: fix this! return hex.EncodeToString(blob) } diff --git a/stratum/handlers.go b/stratum/handlers.go index 7632fc5..4b907e9 100644 --- a/stratum/handlers.go +++ b/stratum/handlers.go @@ -6,7 +6,7 @@ import ( "strings" "sync/atomic" - "../util" + "github.com/kevacoin-project/keva-stratum/util" ) var noncePattern *regexp.Regexp diff --git a/stratum/miner.go b/stratum/miner.go index c857924..8f83850 100644 --- a/stratum/miner.go +++ b/stratum/miner.go @@ -10,8 +10,8 @@ import ( "sync/atomic" "time" - "../hashing" - "../util" + "github.com/kevacoin-project/keva-stratum/hashing" + "github.com/kevacoin-project/keva-stratum/util" ) type Job struct { @@ -152,7 +152,7 @@ func (m *Miner) processShare(s *StratumServer, cs *Session, job *Job, t *BlockTe } else { //convertedBlob = cnutil.ConvertBlob(shareBuff) // TODO: fix this. - convertedBlob = nill + convertedBlob = []byte("fix this!") hashBytes = hashing.Hash(convertedBlob, false) } diff --git a/stratum/stratum.go b/stratum/stratum.go index b491a80..1955d1e 100644 --- a/stratum/stratum.go +++ b/stratum/stratum.go @@ -13,9 +13,9 @@ import ( "sync/atomic" "time" - "../pool" - "../rpc" - "../util" + "github.com/kevacoin-project/keva-stratum/pool" + "github.com/kevacoin-project/keva-stratum/rpc" + "github.com/kevacoin-project/keva-stratum/util" ) type StratumServer struct {