mirror of
https://github.com/fluencelabs/tendermint
synced 2025-04-25 14:52:17 +00:00
config: disable_data_hash (for testing)
This commit is contained in:
parent
196af01707
commit
898f44ddda
@ -70,6 +70,7 @@ func GetConfig(rootDir string) cfg.Config {
|
||||
mapConfig.SetDefault("cswal_light", false)
|
||||
|
||||
mapConfig.SetDefault("block_size", 10000)
|
||||
mapConfig.SetDefault("disable_data_hash", false)
|
||||
mapConfig.SetDefault("timeout_propose", 3000)
|
||||
mapConfig.SetDefault("timeout_propose_delta", 500)
|
||||
mapConfig.SetDefault("timeout_prevote", 1000)
|
||||
|
@ -88,6 +88,7 @@ func GetConfig(rootDir string) cfg.Config {
|
||||
mapConfig.SetDefault("cswal_light", false)
|
||||
|
||||
mapConfig.SetDefault("block_size", 10000)
|
||||
mapConfig.SetDefault("disable_data_hash", false)
|
||||
mapConfig.SetDefault("timeout_propose", 100)
|
||||
mapConfig.SetDefault("timeout_propose_delta", 1)
|
||||
mapConfig.SetDefault("timeout_prevote", 1)
|
||||
|
@ -336,6 +336,10 @@ type Data struct {
|
||||
}
|
||||
|
||||
func (data *Data) Hash() []byte {
|
||||
if config.GetBool("disable_data_hash") {
|
||||
data.hash = []byte{}
|
||||
return data.hash
|
||||
}
|
||||
if data.hash == nil {
|
||||
txs := make([]interface{}, len(data.Txs))
|
||||
for i, tx := range data.Txs {
|
||||
|
Loading…
x
Reference in New Issue
Block a user