aboutsummaryrefslogtreecommitdiffstats
path: root/core
diff options
context:
space:
mode:
authorJimmy Hu <jimmy.hu@dexon.org>2019-04-01 18:01:26 +0800
committerWei-Ning Huang <w@byzantine-lab.io>2019-06-15 22:09:55 +0800
commitbde4a6cc02c6806093d2a49a86463f81358ca3d8 (patch)
treebc3d617f8ff755f6cca5c4fc1dff7b5457845c9f /core
parent3c0372165e723de9f1bd3ea8dacd579810463f6d (diff)
downloadgo-tangerine-bde4a6cc02c6806093d2a49a86463f81358ca3d8.tar
go-tangerine-bde4a6cc02c6806093d2a49a86463f81358ca3d8.tar.gz
go-tangerine-bde4a6cc02c6806093d2a49a86463f81358ca3d8.tar.bz2
go-tangerine-bde4a6cc02c6806093d2a49a86463f81358ca3d8.tar.lz
go-tangerine-bde4a6cc02c6806093d2a49a86463f81358ca3d8.tar.xz
go-tangerine-bde4a6cc02c6806093d2a49a86463f81358ca3d8.tar.zst
go-tangerine-bde4a6cc02c6806093d2a49a86463f81358ca3d8.zip
vendor: sync to latest core (#320)
* vendor: sync to latest core * dex, core: fix conflict x
Diffstat (limited to 'core')
-rw-r--r--core/headerchain.go8
1 files changed, 4 insertions, 4 deletions
diff --git a/core/headerchain.go b/core/headerchain.go
index 0c2000064..b6aa66b60 100644
--- a/core/headerchain.go
+++ b/core/headerchain.go
@@ -535,15 +535,15 @@ func (hc *HeaderChain) verifyDexonHeader(header *types.Header,
}
}
- if header.Time != uint64(coreBlock.Finalization.Timestamp.UnixNano()/1000000) {
+ if header.Time != uint64(coreBlock.Timestamp.UnixNano()/1000000) {
return fmt.Errorf("timestamp mismatch")
}
- if header.Number.Uint64() != coreBlock.Finalization.Height {
+ if header.Number.Uint64() != coreBlock.Position.Height {
return fmt.Errorf("height mismatch")
}
- if !reflect.DeepEqual(header.Randomness, coreBlock.Finalization.Randomness) {
+ if !reflect.DeepEqual(header.Randomness, coreBlock.Randomness) {
return fmt.Errorf("randomness mismatch")
}
@@ -562,7 +562,7 @@ func (hc *HeaderChain) verifyTSig(coreBlock *coreTypes.Block,
verifierCache *dexCore.TSigVerifierCache) error {
round := coreBlock.Position.Round
- randomness := coreBlock.Finalization.Randomness
+ randomness := coreBlock.Randomness
if round == 0 {
return nil