block/state: gas price for block and tx

This commit is contained in:
Ethan Buchman
2015-03-18 02:12:03 -07:00
committed by Jae Kwon
parent 7a33aba6e5
commit f384d10a05
4 changed files with 30 additions and 15 deletions

View File

@@ -107,12 +107,16 @@ type Header struct {
Height uint
Time time.Time
Fees uint64
GasPrice uint64
NumTxs uint
LastBlockHash []byte
LastBlockParts PartSetHeader
StateHash []byte
}
// possible for actual gas price to be less than 1
var GasPriceDivisor = 1000000
func (h *Header) Hash() []byte {
buf := new(bytes.Buffer)
hasher, n, err := sha256.New(), new(int64), new(error)